This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DM3730 wifi mmc1 sdio port issue

Prodigy 130 points

Replies: 4

Views: 2120

Hi All :

I am using beagle board as reference design

which is OMAP DM3730 and  kernel version is 2.6.32

I want to use wifi module which is mmc1 and use sdio interface

so , I deciede to porting form TI Mistral EVM board to beagleboard

after modify following code, i find follwoing error message

"mmc1: starting CMD5 arg 00000000 f;ags 000002e1"

"mmc1: reg failed (CMD5) : -110 : 00000000 00000000 00000000 00000000

it seems in /kernel/driver/mmc/core.c "mmc_rescan" function

sdio will return timeout error message  if sdio core use mmc_send_io_op_cond to communication with our wifi module

Dose anyone could give me some suggestion how i can do ?

Here is the porting information from TI Mistral evm board to beagle
board-omap3beagle.c

modify:
static struct twl4030_hsmmc_info mmc[] = {
 {
  .mmc  = 1,
  .wires  = 8,
  .gpio_wp = -1,
 },
 {
  .name   = "bcm4329_wifi_sdio",
  .mmc  = 2,
  .wires  = 4,
  .gpio_cd  =-1,
  .transceiver = true,
  //.ocr_mask = 0x00100000, /* 3.3V */
  .nonremovable   = true,  
 },
 {} /* Terminator */
};

add following variable to board_mux

OMAP3_MUX(UART1_RTS, OMAP_MUX_MODE4 | OMAP_PIN_INPUT),
OMAP3_MUX(UART1_CTS, OMAP_MUX_MODE4 | OMAP_PIN_OUTPUT),
 
OMAP3_MUX(SDMMC2_CLK,    OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP),
OMAP3_MUX(SDMMC2_CMD,  OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP),
OMAP3_MUX(SDMMC2_DAT0, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP),
OMAP3_MUX(SDMMC2_DAT1, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP),
OMAP3_MUX(SDMMC2_DAT2, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP),
OMAP3_MUX(SDMMC2_DAT3, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP),

define new structure :

static struct regulator_consumer_supply omap3evm_vmmc2_supply =
 REGULATOR_SUPPLY("vmmc", "mmci-omap-hs.1");

/* VMMC2 for driving the WL12xx module */
static struct regulator_init_data omap3evm_vmmc2 = {
 .constraints = {
  .valid_ops_mask = REGULATOR_CHANGE_STATUS,
 },
 .num_consumer_supplies  = 1,
 .consumer_supplies = &omap3evm_vmmc2_supply,
};

static struct fixed_voltage_config omap3evm_vwlan = {
 .supply_name            = "vwl1271",
 .microvolts             = 1800000, /* 1.80V */
 //.gpio                   = OMAP3EVM_WLAN_PMENA_GPIO,
 .enable_high            = 1,
 .enabled_at_boot        = 0,
 .init_data              = &omap3evm_vmmc2,
};


static struct platform_device omap3evm_wlan_regulator = {
 .name           = "reg-fixed-voltage",
 .id             = 1,
 .dev = {
  .platform_data  = &omap3evm_vwlan,
 },
};

finally , register it on omap3_beagle_init
platform_device_register(&omap3evm_wlan_regulator);

4 Replies

  • Hi,

    please use our WiKi page in http://processors.wiki.ti.com/index.php/OMAP_Wireless_Connectivity_Hardware_Porting_for_AM37x_Platform as a refference, that describes how to port mm2 for AM37x platform

    Regards,

    Eyal

  • In reply to Eyal a:

    Hi Eyal :

    Thank you for your information

    I wonder to know microvolts variable

    static struct fixed_voltage_config omap3evm_vwlan = {
    .supply_name = "vwl1271",
    .microvolts = 1800000, /* 1.80V */
    .gpio = OMAP3EVM_WLAN_PMENA_GPIO,
    .startup_delay = 70000, /* 70ms */
    .enable_high = 1,
    .enabled_at_boot = 0,
    .init_data = &omap3evm_vmmc2,
    };

    if I set the microvolts=1800000 , mmc_select_voltange will return fail
    But if set microvolts=3200000, everything work well and my wifi module will be porbe and initialize
    I don't know what's happen for setting this variable
  • In reply to YiChun Lu:

    Hi Mr Lu.

    This is a result of CMD 5 in the SDIO.

    TI WLAN operates on 1.8V so level-shifter is inserted in all lines (SDIO+enable).

    Other WIFI needs different values

    - Elad.

    - Elad Raz

    CTO

    www.integrity-project.com

  • In reply to Elad Raz92038:

    Hi Elad :

    I am rookie for SDIO communication , if I misunderstanding , please correct me

    For your reply , it mean after SDIO CMD5,

    It will return the ocr which is 1.8V ?

This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.