summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/wil6210/pmc.c
AgeCommit message (Collapse)Author
2018-02-27wil6210: infrastructure for multiple virtual interfacesLior David
Simple infrastructure changes for supporting multiple virtual interfaces (multiple VIFs). It is still not possible to add new VIFs so the only VIF belongs to the main interface. Main changes: 1. Add MAC ID(mid) argument to wmi_send and wmi_call to allow invoking WMI commands on different VIFs. 2. Similarly, in WMI event handler look at the mid reported by FW and extract VIF structure (currently only for main interface). All WMI event handlers operate on wil6210_vif structure so they know on which VIF they were called. 3. Trivial changes to use wil6210_vif structure and MID throughout the code. 4. Various changes to logging to report MID. More complete multiple VIFs support will be added gradually in next patches. Signed-off-by: Lior David <liord@codeaurora.org> Signed-off-by: Maya Erez <merez@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2018-01-09wil6210: support 40bit DMA addressesLazar Alexei
Add the option to support 40bit addresses since some platforms may not support 48bits but support 40bits Signed-off-by: Lazar Alexei <qca_ailizaro@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2017-04-13wil6210: fix array out of bounds access in pmcDedy Lansky
Array index 'i' is used before limits check. Fix this by doing limits check first. Signed-off-by: Dedy Lansky <qca_dlansky@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-03-09wil6210: set dma mask to reflect device capabilityHamad Kadmany
device supports 48bit addresses, reflect that by setting the dma mask accordingly. Signed-off-by: Hamad Kadmany <qca_hkadmany@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2017-01-27wil6210: remove __func__ from debug printoutsLazar Alexei
__func__ is automatically added to printouts by dynamic debug mechanism and by wil_info/wil_err macros. Remove __func__ from debug printouts to avoid duplication. Signed-off-by: Lazar Alexei <qca_ailizaro@qca.qualcomm.com> Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2016-12-01wil6210: validate wil_pmc_alloc parametersMaya Erez
num_descriptors and descriptor_size needs to be checked for: 1) not being negative values 2) no overflow occurs when these are multiplied together as done in wil_pmc_read. An overflow of two signed integers is undefined behavior. Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2015-10-09wil6210: pmc logger bug fixVladimir Shulman
When allocating pmc descriptor, the structure is initially created on stack and later copied to the physical ring (device) memory. The descriptor structure must be initialized to zero to avoid garbage configuration, which may result in pmc mechanism malfunctioning. Signed-off-by: Vladimir Shulman <QCA_shulmanv@QCA.qualcomm.com> Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2015-05-22wil6210: fix format specifier for dma_addr_tVladimir Kondratiev
Fix format specifier used for dma_addr_t, namely use %pad Debug print virtual address for the same buffer as well. Fixes: dc16427bbe65 ("wil6210: Add pmc debug mechanism memory management") Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2015-05-04wil6210: Add pmc debug mechanism memory managementVladimir Kondratiev
Pmc is a hardware debug mechanism which allows capturing phy data, packets, and internally generated events and messages synchronized and time stamped by the hardware. It requires memory buffers allocated by the driver in order to be used by hardware dma to upstream real time debug data to host memory. Driver will handle memory allocation and release, and fetching the data from the memory to application layer via debug file system. The configuration of pmc is handled entirely by the application layer. Signed-off-by: Vladimir Shulman <qca_shulmanv@qca.qualcomm.com> Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>