main.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * Device probe and register.
  4. *
  5. * Copyright (c) 2017-2020, Silicon Laboratories, Inc.
  6. * Copyright (c) 2010, ST-Ericsson
  7. * Copyright (c) 2006, Michael Wu <flamingice@sourmilk.net>
  8. * Copyright 2004-2006 Jean-Baptiste Note <jbnote@gmail.com>, et al.
  9. */
  10. #ifndef WFX_MAIN_H
  11. #define WFX_MAIN_H
  12. #include <linux/device.h>
  13. #include <linux/gpio/consumer.h>
  14. #include "hif_api_general.h"
  15. struct wfx_dev;
  16. struct hwbus_ops;
  17. struct wfx_platform_data {
  18. /* Keyset and ".sec" extension will be appended to this string */
  19. const char *file_fw;
  20. const char *file_pds;
  21. struct gpio_desc *gpio_wakeup;
  22. /*
  23. * if true HIF D_out is sampled on the rising edge of the clock
  24. * (intended to be used in 50Mhz SDIO)
  25. */
  26. bool use_rising_clk;
  27. };
  28. struct wfx_dev *wfx_init_common(struct device *dev,
  29. const struct wfx_platform_data *pdata,
  30. const struct hwbus_ops *hwbus_ops,
  31. void *hwbus_priv);
  32. int wfx_probe(struct wfx_dev *wdev);
  33. void wfx_release(struct wfx_dev *wdev);
  34. bool wfx_api_older_than(struct wfx_dev *wdev, int major, int minor);
  35. int wfx_send_pds(struct wfx_dev *wdev, u8 *buf, size_t len);
  36. #endif