Skip to content

Commit

Permalink
net: wireless: iwlegacy: fix build error for il_pm_ops
Browse files Browse the repository at this point in the history
Fix build error for il_pm_ops if CONFIG_PM is set
but CONFIG_PM_SLEEP is not set.

ERROR: "il_pm_ops" [drivers/net/wireless/iwlegacy/iwl4965.ko] undefined!
ERROR: "il_pm_ops" [drivers/net/wireless/iwlegacy/iwl3945.ko] undefined!
make[1]: *** [__modpost] Error 1
make: *** [modules] Error 2

Signed-off-by: Yijing Wang <wangyijing@huawei.com>
Cc: Stanislaw Gruszka <sgruszka@redhat.com>
Cc: "John W. Linville" <linville@tuxdriver.com>
Cc: netdev@vger.kernel.org
Cc: linux-wireless@vger.kernel.org
Cc: Jingoo Han <jg1.han@samsung.com>
Acked-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Yijing Wang authored and John W. Linville committed Jun 12, 2013
1 parent 87ccee4 commit 71aa5bb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/net/wireless/iwlegacy/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -1832,16 +1832,16 @@ u32 il_usecs_to_beacons(struct il_priv *il, u32 usec, u32 beacon_interval);
__le32 il_add_beacon_time(struct il_priv *il, u32 base, u32 addon,
u32 beacon_interval);

#ifdef CONFIG_PM
#ifdef CONFIG_PM_SLEEP
extern const struct dev_pm_ops il_pm_ops;

#define IL_LEGACY_PM_OPS (&il_pm_ops)

#else /* !CONFIG_PM */
#else /* !CONFIG_PM_SLEEP */

#define IL_LEGACY_PM_OPS NULL

#endif /* !CONFIG_PM */
#endif /* !CONFIG_PM_SLEEP */

/*****************************************************
* Error Handling Debugging
Expand Down

0 comments on commit 71aa5bb

Please sign in to comment.