mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-15 01:01:56 -04:00
qcacld-3.0: Add support for pld_is_fw_down in usb
Add support for pld_is_fw_down in usb case. Change-Id: I2103964c6413734ec4f156fe3058e67984b8e09b CRs-fixed: 2432112
This commit is contained in:
parent
60a34715cf
commit
1438216e41
3 changed files with 24 additions and 3 deletions
|
|
@ -1615,8 +1615,8 @@ int pld_is_qmi_disable(struct device *dev)
|
|||
*
|
||||
* This API will be called to check if WLAN FW is down or not.
|
||||
*
|
||||
* Return: 1 FW is down
|
||||
* 0 FW is not down
|
||||
* Return: 0 FW is not down
|
||||
* Otherwise FW is down
|
||||
* Always return 0 for unsupported bus type
|
||||
*/
|
||||
int pld_is_fw_down(struct device *dev)
|
||||
|
|
@ -1632,7 +1632,9 @@ int pld_is_fw_down(struct device *dev)
|
|||
ret = pld_pcie_is_fw_down(dev);
|
||||
break;
|
||||
case PLD_BUS_TYPE_SDIO:
|
||||
break;
|
||||
case PLD_BUS_TYPE_USB:
|
||||
ret = pld_usb_is_fw_down(dev);
|
||||
break;
|
||||
default:
|
||||
pr_err("Invalid device type %d\n", type);
|
||||
|
|
|
|||
|
|
@ -253,6 +253,11 @@ int pld_usb_wlan_enable(struct device *dev, struct pld_wlan_enable_cfg *config,
|
|||
return cnss_wlan_enable(dev, &cfg, cnss_mode, host_version);
|
||||
}
|
||||
|
||||
int pld_usb_is_fw_down(struct device *dev)
|
||||
{
|
||||
return cnss_usb_is_device_down(dev);
|
||||
}
|
||||
|
||||
#else /* CONFIG_PLD_USB_CNSS */
|
||||
|
||||
struct usb_driver pld_usb_ops = {
|
||||
|
|
@ -317,4 +322,10 @@ int pld_usb_wlan_enable(struct device *dev, struct pld_wlan_enable_cfg *config,
|
|||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
int pld_usb_is_fw_down(struct device *dev)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif /* CONFIG_PLD_USB_CNSS */
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2016-2018 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2016-2019 The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for
|
||||
* any purpose with or without fee is hereby granted, provided that the
|
||||
|
|
@ -26,6 +26,8 @@ void pld_usb_unregister_driver(void);
|
|||
int pld_usb_get_ce_id(int irq);
|
||||
int pld_usb_wlan_enable(struct device *dev, struct pld_wlan_enable_cfg *config,
|
||||
enum pld_driver_mode mode, const char *host_version);
|
||||
int pld_usb_is_fw_down(struct device *dev);
|
||||
|
||||
#else
|
||||
static inline int pld_usb_register_driver(void)
|
||||
{
|
||||
|
|
@ -42,6 +44,12 @@ static inline int pld_usb_wlan_enable(struct device *dev,
|
|||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline int pld_usb_is_fw_down(struct device *dev)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
static inline int
|
||||
|
|
|
|||
Loading…
Reference in a new issue