~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/include/linux/platform_data/net-cw1200.h

Version: ~ [ linux-5.13-rc5 ] ~ [ linux-5.12.9 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.42 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.124 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.193 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.235 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.271 ] ~ [ linux-4.8.17 ] ~ [ linux-4.7.10 ] ~ [ linux-4.6.7 ] ~ [ linux-4.5.7 ] ~ [ linux-4.4.271 ] ~ [ linux-4.3.6 ] ~ [ linux-4.2.8 ] ~ [ linux-4.1.52 ] ~ [ linux-4.0.9 ] ~ [ linux-3.18.140 ] ~ [ linux-3.16.85 ] ~ [ linux-3.14.79 ] ~ [ linux-3.12.74 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.5 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /*
  2  * Copyright (C) ST-Ericsson SA 2011
  3  *
  4  * Author: Dmitry Tarnyagin <dmitry.tarnyagin@stericsson.com>
  5  * License terms: GNU General Public License (GPL) version 2
  6  */
  7 
  8 #ifndef CW1200_PLAT_H_INCLUDED
  9 #define CW1200_PLAT_H_INCLUDED
 10 
 11 struct cw1200_platform_data_spi {
 12         u8 spi_bits_per_word;           /* REQUIRED */
 13         u16 ref_clk;                    /* REQUIRED (in KHz) */
 14 
 15         /* All others are optional */
 16         bool have_5ghz;
 17         int reset;                     /* GPIO to RSTn signal (0 disables) */
 18         int powerup;                   /* GPIO to POWERUP signal (0 disables) */
 19         int (*power_ctrl)(const struct cw1200_platform_data_spi *pdata,
 20                           bool enable); /* Control 3v3 / 1v8 supply */
 21         int (*clk_ctrl)(const struct cw1200_platform_data_spi *pdata,
 22                         bool enable); /* Control CLK32K */
 23         const u8 *macaddr;  /* if NULL, use cw1200_mac_template module parameter */
 24         const char *sdd_file;  /* if NULL, will use default for detected hw type */
 25 };
 26 
 27 struct cw1200_platform_data_sdio {
 28         u16 ref_clk;                    /* REQUIRED (in KHz) */
 29 
 30         /* All others are optional */
 31         bool have_5ghz;
 32         bool no_nptb;       /* SDIO hardware does not support non-power-of-2-blocksizes */
 33         int reset;          /* GPIO to RSTn signal (0 disables) */
 34         int powerup;        /* GPIO to POWERUP signal (0 disables) */
 35         int irq;            /* IRQ line or 0 to use SDIO IRQ */
 36         int (*power_ctrl)(const struct cw1200_platform_data_sdio *pdata,
 37                           bool enable); /* Control 3v3 / 1v8 supply */
 38         int (*clk_ctrl)(const struct cw1200_platform_data_sdio *pdata,
 39                         bool enable); /* Control CLK32K */
 40         const u8 *macaddr;  /* if NULL, use cw1200_mac_template module parameter */
 41         const char *sdd_file;  /* if NULL, will use default for detected hw type */
 42 };
 43 
 44 
 45 /* An example of SPI support in your board setup file:
 46 
 47    static struct cw1200_platform_data_spi cw1200_platform_data = {
 48        .ref_clk = 38400,
 49        .spi_bits_per_word = 16,
 50        .reset = GPIO_RF_RESET,
 51        .powerup = GPIO_RF_POWERUP,
 52        .macaddr = wifi_mac_addr,
 53        .sdd_file = "sdd_sagrad_1091_1098.bin",
 54   };
 55   static struct spi_board_info myboard_spi_devices[] __initdata = {
 56        {
 57                .modalias = "cw1200_wlan_spi",
 58                .max_speed_hz = 52000000,
 59                .bus_num = 0,
 60                .irq = WIFI_IRQ,
 61                .platform_data = &cw1200_platform_data,
 62                .chip_select = 0,
 63        },
 64   };
 65 
 66  */
 67 
 68 /* An example of SDIO support in your board setup file:
 69 
 70   static struct cw1200_platform_data_sdio my_cw1200_platform_data = {
 71         .ref_clk = 38400,
 72         .have_5ghz = false,
 73         .sdd_file = "sdd_myplatform.bin",
 74   };
 75   cw1200_sdio_set_platform_data(&my_cw1200_platform_data);
 76 
 77  */
 78 
 79 void __init cw1200_sdio_set_platform_data(struct cw1200_platform_data_sdio *pdata);
 80 
 81 #endif /* CW1200_PLAT_H_INCLUDED */
 82 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | Wiki (Japanese) | Wiki (English) | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

osdn.jp