Skip to content

Commit

Permalink
blackfin: Fixup export.h includes
Browse files Browse the repository at this point in the history
Commit 8dc7a9c ("blackfin: Add export.h to files using
EXPORT_SYMBOL/THIS_MODULE") inserted some of the include statements into
sections protected by an unrelated #if CONFIG_... statement. This can cause,
depending on the configuration used, warnings like this one:

	arch/blackfin/mach-bf537/boards/stamp.c:2940: warning: data definition has no type or storage class
	arch/blackfin/mach-bf537/boards/stamp.c:2940: warning: type defaults to ‘int’ in declaration of ‘EXPORT_SYMBOL’
	arch/blackfin/mach-bf537/boards/stamp.c:2940: warning: parameter names (without types) in function declaration

This patch fixes it by moving the includes out of the #if protected sections.

Signed-off-by: Lars-Peter Clausen <[email protected]>
Acked-by: Mike Frysinger <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
  • Loading branch information
larsclausen authored and aet00 committed Nov 14, 2011
1 parent edb0a64 commit 9059054
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion arch/blackfin/mach-bf527/boards/cm_bf527.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
*/

#include <linux/device.h>
#include <linux/export.h>
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
Expand Down Expand Up @@ -811,7 +812,6 @@ static struct platform_device bfin_sport1_uart_device = {
#if defined(CONFIG_KEYBOARD_GPIO) || defined(CONFIG_KEYBOARD_GPIO_MODULE)
#include <linux/input.h>
#include <linux/gpio_keys.h>
#include <linux/export.h>

static struct gpio_keys_button bfin_gpio_keys_table[] = {
{BTN_0, GPIO_PF14, 1, "gpio-keys: BTN0"},
Expand Down
2 changes: 1 addition & 1 deletion arch/blackfin/mach-bf527/boards/ezbrd.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
*/

#include <linux/device.h>
#include <linux/export.h>
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
Expand Down Expand Up @@ -684,7 +685,6 @@ static struct platform_device bfin_sport1_uart_device = {
#if defined(CONFIG_KEYBOARD_GPIO) || defined(CONFIG_KEYBOARD_GPIO_MODULE)
#include <linux/input.h>
#include <linux/gpio_keys.h>
#include <linux/export.h>

static struct gpio_keys_button bfin_gpio_keys_table[] = {
{BTN_0, GPIO_PG0, 1, "gpio-keys: BTN0"},
Expand Down
2 changes: 1 addition & 1 deletion arch/blackfin/mach-bf537/boards/cm_bf537e.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
*/

#include <linux/device.h>
#include <linux/export.h>
#include <linux/etherdevice.h>
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
Expand Down Expand Up @@ -579,7 +580,6 @@ static struct platform_device bfin_sport1_uart_device = {

#if defined(CONFIG_BFIN_MAC) || defined(CONFIG_BFIN_MAC_MODULE)
#include <linux/bfin_mac.h>
#include <linux/export.h>
static const unsigned short bfin_mac_peripherals[] = P_MII0;

static struct bfin_phydev_platform_data bfin_phydev_data[] = {
Expand Down
2 changes: 1 addition & 1 deletion arch/blackfin/mach-bf537/boards/cm_bf537u.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include <linux/device.h>
#include <linux/etherdevice.h>
#include <linux/export.h>
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
Expand Down Expand Up @@ -544,7 +545,6 @@ static struct platform_device bfin_sport1_uart_device = {

#if defined(CONFIG_BFIN_MAC) || defined(CONFIG_BFIN_MAC_MODULE)
#include <linux/bfin_mac.h>
#include <linux/export.h>
static const unsigned short bfin_mac_peripherals[] = P_MII0;

static struct bfin_phydev_platform_data bfin_phydev_data[] = {
Expand Down
2 changes: 1 addition & 1 deletion arch/blackfin/mach-bf537/boards/dnp5370.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
*/

#include <linux/device.h>
#include <linux/export.h>
#include <linux/kernel.h>
#include <linux/platform_device.h>
#include <linux/io.h>
Expand Down Expand Up @@ -49,7 +50,6 @@ static struct platform_device rtc_device = {

#if defined(CONFIG_BFIN_MAC) || defined(CONFIG_BFIN_MAC_MODULE)
#include <linux/bfin_mac.h>
#include <linux/export.h>
static const unsigned short bfin_mac_peripherals[] = P_RMII0;

static struct bfin_phydev_platform_data bfin_phydev_data[] = {
Expand Down
1 change: 1 addition & 0 deletions arch/blackfin/mach-bf537/boards/pnav10.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

#include <linux/device.h>
#include <linux/etherdevice.h>
#include <linux/export.h>
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
Expand Down
2 changes: 1 addition & 1 deletion arch/blackfin/mach-bf537/boards/stamp.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
*/

#include <linux/device.h>
#include <linux/export.h>
#include <linux/kernel.h>
#include <linux/platform_device.h>
#include <linux/io.h>
Expand Down Expand Up @@ -2002,7 +2003,6 @@ static struct adp8870_backlight_platform_data adp8870_pdata = {

#if defined(CONFIG_BACKLIGHT_ADP8860) || defined(CONFIG_BACKLIGHT_ADP8860_MODULE)
#include <linux/i2c/adp8860.h>
#include <linux/export.h>
static struct led_info adp8860_leds[] = {
{
.name = "adp8860-led7",
Expand Down
2 changes: 1 addition & 1 deletion arch/blackfin/mach-bf537/boards/tcm_bf537.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

#include <linux/device.h>
#include <linux/etherdevice.h>
#include <linux/export.h>
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
Expand Down Expand Up @@ -546,7 +547,6 @@ static struct platform_device bfin_sport1_uart_device = {

#if defined(CONFIG_BFIN_MAC) || defined(CONFIG_BFIN_MAC_MODULE)
#include <linux/bfin_mac.h>
#include <linux/export.h>
static const unsigned short bfin_mac_peripherals[] = P_MII0;

static struct bfin_phydev_platform_data bfin_phydev_data[] = {
Expand Down

0 comments on commit 9059054

Please sign in to comment.