wl12xx.h 810 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * This file is part of wl12xx
  4. *
  5. * Copyright (C) 2009 Nokia Corporation
  6. *
  7. * Contact: Luciano Coelho <luciano.coelho@nokia.com>
  8. */
  9. #ifndef _LINUX_WL12XX_H
  10. #define _LINUX_WL12XX_H
  11. #include <linux/err.h>
  12. struct wl1251_platform_data {
  13. int power_gpio;
  14. /* SDIO only: IRQ number if WLAN_IRQ line is used, 0 for SDIO IRQs */
  15. int irq;
  16. bool use_eeprom;
  17. };
  18. #ifdef CONFIG_WILINK_PLATFORM_DATA
  19. int wl1251_set_platform_data(const struct wl1251_platform_data *data);
  20. struct wl1251_platform_data *wl1251_get_platform_data(void);
  21. #else
  22. static inline
  23. int wl1251_set_platform_data(const struct wl1251_platform_data *data)
  24. {
  25. return -ENOSYS;
  26. }
  27. static inline
  28. struct wl1251_platform_data *wl1251_get_platform_data(void)
  29. {
  30. return ERR_PTR(-ENODATA);
  31. }
  32. #endif
  33. #endif