summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-11-10Revert "dw3000_stm: uninterruptedly wait for pending_work to complete"android-12.0.0_r0.42android-12.0.0_r0.36android-12.0.0_r0.26android-gs-raviole-5.10-android12-qpr1-dJonglin Lee
This reverts commit 558a7ed1bf3c14ba0f01b91d04a1bac51ab9c97e. Reason for revert: 100% deadlock if receive signal during wait Bug: 205397250 Change-Id: I985a84699732c3221ff842ab5f90dda3cb82bf39 Signed-off-by: Jonglin Lee <jonglin@google.com>
2021-11-02dw3000_stm: uninterruptedly wait for pending_work to completeWoody Lin
Data assigned to stm->generic_work can be a local variable (e.g.: dw3000_state_start) that discarded after function returns, and in this case, dw3000_event_thread will get an invalid generic_work that causes data abort. To fix it, repeats the wait_event_interruptible_locked_irq until the event condition meets, that is, ignore the signal interrupting case. Bug: 199454999 Change-Id: I1a244e2e50c14de2c471f0e0f696c8b403881fcb (cherry picked from commit 0ea8be1ed473db3a0fe5dab4ed11d13ea8fd63ee)
2021-09-24dw3000: increase the wifi coex margin from 300ms to 500ms to avoid ↵Clement Viel
interferences. Bug: 171489641 Signed-off-by: Clement Viel <clement.viel@qorvo.com> Change-Id: I7f8179b99d058a67e180a2d6e13df7965c693397
2021-09-21Uwb stack feature complete for MCTTJean-Michel RIOT
mac/fira: update mac with QSWG fixes Improve: - sts index and hopping calculation - UCI max measurements testing - Controlee behaviour, don't keep Rx on all time after sy dw3000: fix CFO adjust in rx_get_frame(), closes UWB-1878 mac/fira: coding style dw3000: change default xtal trim to 0x1f This value is measured on multiple E0 samples, it's a mean value to have a maximum CFO of 8 ppm mac/fira: add 2us margin on tx frames after rcm mac/fira: use a helper to set the ranging info status mac: add slot_index to identify faulty status BUG: 194303361 Change-Id: I463b341fc4ac617593358d8f64f90f4b5753a3d1 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-09-21dw3000: add rx event counters tracesClement Viel
dw3000_get_counters_first_part and dw3000_get_counters_second_part activates counters for rx events. Bug: 194303455 Signed-off-by: Clement Viel <clement.viel@qorvo.com> Change-Id: I908cf02ec06d545f009f979dac78f868c5d51969
2021-09-20dw3000: override SP0 rx antennaClement Viel
To activate "insmod dw3000.ko sp0_rx_antenna=-1" Bug: 197922222 Signed-off-by: Clement Viel <clement.viel@qorvo.com> Change-Id: I3d68c8086493f5e459351ef6ff902ef60150a5cc
2021-09-20Revert "UWB: pdoa snapping fix - new feature"Victor Liu
This reverts commit 9b4d2c16be040ce1529bac9cd5df1a3aa972352b. Bug: 198208484 Change-Id: I36d9ada165563177bba89b437142fe84126cdf98
2021-09-15kernel/drivers/net: implement preamble code interface change, refs UWB-1125David Girault
mac/fira: use channel and preamble code from session parameters, refs UWB-1125 - If specified, use the channel and preamble code from the session parameters, else use the current PIB parameters. - FiRa interface change: - Now channel and preamble code session parameters are used to setup the radio, they were previously only used for crypto. - Also if not set, the real values are taken from the current driver setting. Previously, they have to be set manually or else 0 was used, which was not valid. mac: allow setting channel parameters for multiple frame accesses, refs UWB-1125 - When a specific channel (page, channel and preamble code) is requested for an access, set it at access start and restore channel after the access. - LLHW interface change: - UWB drivers should set llhw->current_preamble_code before registration to the default preamble code index for this device. - MCPS no longer calls set_channel with a zero preamble code, it uses the value set in llhw->current_preamble_code. - MCPS can now call set_channel when the device is started. In this case, the new channel parameters should be set so that they are used for the following transmissions and receptions. Special care should be taken by the driver to avoid any significant clock discontinuity. - When only preamble code is changed, the driver can be optimized to avoid costly operations done on channel change. dw3000: update set_channel() callback, refs UWB-1880 - Ensure only pcode is changed if channel stay the same - Support reconfigure during wakeup - Move calib update in dw3000_configure_chan_ctrl() BUG: 196395783 Change-Id: Ic5664cf64c15df6d4f2e6abd03042f682ab01f00 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-31dw3000 : change PLL calibration routineClément Viel
- clear PLL lock bit when configuring rf - disable Pre-buffer-enable for Ch9 PLL calibration for E0 - Clear ICAS, RCAS and CH5_CAL_PREBUF bits in PLL_CAL_ID register Bug: 196842697 Change-Id: I3e42b5c36feec29c8fdbbc5c128155fb7b1d9915 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-27dw3000: use wifi coex gpio 4 and increase wifi coex margin to 400usSaad Zouiten
Bug: 171489641 Change-Id: Id17b68a64d01307341b1ce2356568301bfb454c8 Signed-off-by: Jonathan Diguet <jonathan.diguet@qorvo.com>
2021-08-26Improve Fira frame duration calculationJohann Cahier
dw3000: improve frame duration calculation dw3000: re-enable with_shr in smart power calculation dw3000: disable sts for conttx Bug: 189155078 Change-Id: Ia0ddaabdab59ef2a5d34c98cfcfba5731f551de8 Signed-off-by: Jonathan Diguet <jonathan.diguet@qorvo.com>
2021-08-26dw3000: add runtime modification of pgdelayJerome Grard
BUG: 194510102 Change-Id: Ib078d9097a6edf7b5212f12b8e5d4b44543c9ea9 Signed-off-by: Mathieu Perrier <mathieu.perrier@qorvo.com>
2021-08-19dw3000: backport fixes on smart power calculation, refs UWB-1729Johann Cahier
BUG: 189155078 Change-Id: Iae908ca2308f5e719b88a2515e4e943e98505578 Signed-off-by: Mathieu Perrier <mathieu.perrier@qorvo.com>
2021-08-19mac/fira: add rx margin to controlees access, refs UWB-1559Martin Frétigné
BUG: 194543247 Change-Id: Ic640feb9f6d2d70b119366ceeebcc18c430c5bfd Signed-off-by: Mathieu Perrier <mathieu.perrier@qorvo.com>
2021-08-19Avoid synchronizing the clock in the middle of a blockSaad Zouiten
BUG: 196974358 Change-Id: I3ecb5a188879d2a66af4374fb8c014079871a026 Signed-off-by: Mathieu Perrier <mathieu.perrier@qorvo.com>
2021-08-19dw3000_core: fix dw3000_force_clocks.Philippe Skowronski
This fixes the wpan-testmode error BUG: 194941105 Change-Id: I4e85f70ab0086aae5848bb8c8c3d0f591ac5a9f0 Signed-off-by: Mathieu Perrier <mathieu.perrier@qorvo.com>
2021-08-17UWB: pdoa snapping fix - new featureClement Viel
contains the following 5403bebe: dw3000: update xtal_trim in controlee if needed, closes UWB-1653 8d574d79: dw3000: Add DW3000_CFO_THRESHOLD define, refs UWB-1653 ea7eee91: dw3000: oscillate XTAL trim if controller, closes UWB-1654 564eb550: dw3000: change dw3000_prog_xtrim to include xtal_bias, refs UWB-1654 b00f265d: dw3000: take care of CFO when returning PDoA FOM, refs UWB-1652 248bfa89: dw3000: add dw3000_read_clockoffset() function, refs UWB-1652 644c9568: dw3000: move and fix header of dw3000_read_all_sys_status() 96556dae: mac/fira: use new RANGING_ROUND flags to inform driver, refs UWB-1651 4585486e: mac/simple_ranging: use new RANGING_ROUND flags to inform driver, refs UWB-1651 f942bc96: mac: add MCPS802154_(TX_FRAME|RX_INFO)_RANGING_ROUND flags, refs UWB-1651 BUG: 191704701 Change-Id: I2962a276fc8068389ca37286875bf624c847ee9c Signed-off-by: Mathieu Perrier <mathieu.perrier@qorvo.com>
2021-08-14Revert "mac: fix timing issues for MCTT / new feature"Philippe Skowronski
This reverts commit c9e3334cabf922eab40888bbd0ed522841c5d621. BUG: 192387172 Change-Id: I5348240ed10cbc0b112ff5301e7be1776f1a8f37 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-13dw3000: fix the limit of DW3000_RSSI_REPORTS_MAX rssi reports, refs UWB-1713 ↵Yvan Roch
b/194303455 BUG: 194303455 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com> Change-Id: I8822531adb19e250489e69d2419ced23a392a0ed
2021-08-13[Regulatory] Test setup instructions b/194941105Romuald Despres
dw3000: add continuous TX testmode a451db482c94eb0e3dc995bc1b13405ef3ed15ca dw3000: add calibration key for phrMode a4c73d0bcf4ee0677b574b01983e85fd88a29b74 dw3000: fix channel 9 on D0, closes UWB-1685 01fab899e7e797a52789084013e2f8080673aef4 BUG: 194941105 Change-Id: I235f20d6cb1966a1097a5a1d1411dba15ee4f791 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-12Fira access controlee rx frame: add MCPS802154_RX_INFO_TIMESTAMP_DTU flags ↵Philippe Skowronski
b/192407649 Add MCPS802154_RX_INFO_TIMESTAMP_DTU flag to handle timestamp_dtu field. BUG: 192407649 Change-Id: I4888b8674b83f47d7b56c78c5369e69f53b38753 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-12dw3000_stm: increase dw3000 worker thread priority b/171489641 b/194543247.Philippe Skowronski
Increase dw3000 worker thread priority to MAX_USER_RT_PRIO minus one (maximum priority for the real-time policies). Increase dw3000 worker thread sched_util_min attr to SCHED_CAPACITY_SCALE to increase CPU freg. To be improved later. BUG: 171489641 BUG: 194543247 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com> Change-Id: Ib7d7964e8b6bb65c7803b01b8303809c96333a04
2021-08-12mac/fira_access.c return is missingJean-Michel RIOT
BUG: 192387172 Change-Id: Ib2778b3706cee0025f3ae292befec57b39616363 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-12Revert "mac: do not propagate ARFE error upper than fproc layer b/192407649."Jean-Michel RIOT
This reverts commit 1b05dccf71ec88c68748789b037eb3c01c724201. BUG: 192407649 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com> Change-Id: Ib2e141d65fdcc215792e455d11a73fa38b55f5cf
2021-08-12Revert dw3000: change XTAL_TRIM default value b-194303361Jean-Michel RIOT
BUG: 194303361 Change-Id: Ide16b5554dc0a80d5d9e3820e4e41cdc27615c64 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11kernel : WiFi Coexistence b/171489641Saad Zouiten
dw3000: avoid changing the wifi gpio elsewhere than tx/rx for set and idle for reset c4e960f48ef1c369be721f453483d7d39059b298 dw3000: release the coex gpio when idling 2fbd077af927ebbfe595ca475dd824cf4ba96e35 dw3000: add wifi coex margin to the module parameter 315263a480518d4f13d3568b600d19786127a797 dw3000: no need to use need_ranging_clock to control the gpio coex 8997faf5281591b614f7f3573e9eb659715b3c28 BUG: 171489641 Change-Id: I1acd977617c0f1538dee0a5c74f57a4c8e1bed89 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11[Regulatory] Implement UWB Pulse ShapeJean-Michel RIOT
dw3000: set alternate pulse shape for japan, Closes UWB-1688 87644611cbd6a1cfde92850033db3ef2d998f397 Bug: 194806491 Bug: 185029345 Change-Id: I88b354599d898796f32f3bc683691a6173fd7bca Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11dw3000: change XTAL_TRIM default valueClement Viel
D0 and E0 communication can lead to big clock offset gaps. Setting 0x20 as default value reduce the clock offset gap to acceptable values. Bug: 194303361 Change-Id: I85b8ce05fb770760297d66ae3580ee5eba9069d4 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11Custom definition of phase difference to AoA mappingJean-Michel RIOT
dw3000: DGC LUT load rework, closes UWB-1627 cc07cd9f4a594b2a25bd4fd020b36a5182610895 mac: use the AoA value computed the driver, refs UWB-1236 ade61cf74b403447173f36489071e4d85a844fd5 dw3000: add PDoA to AoA lookup tables, refs UWB-1236 d3aeacdda7978af9536b706015ed382dab452ebb Bug: 172565633 Change-Id: Icf514ffb41e2b400c4002d8b223ce78ae40ce3ba Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11change channel if current one is restrictedClement Viel
Bug: 194829842 Change-Id: I69e2eb07895e941f8fff89f9587250ad4e6c3eaf Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11dw3000: enable bandwidth compensation featureClement Viel
dw3000: remove useless parameter and debug logs The DW3720 is capable of adapting its bandwidth depending on the temperature. This patch allow activation of this feature Bug: 184062058 Change-Id: If331ffde5dac75a1f939b71ed2797092adeba12e Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11Implement DW3720 Configuration For Japan Regulatory ComplianceJean-Michel RIOT
dw3000: add param to restrict channels that can be used, refs UWB-1246 6ed8cb7846ac77a7d21f22b4c45ca3bffcbf0c24 Bug: 185029345 Change-Id: I1f14531fa70c07a75ac2ae4f330ddb81114f5a8f Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11dw3000: allow 0 power values in RSSI tracesClement Viel
Returning an error when CIA/power value is 0 hangs the state machine. This patch only warns the user that value is 0. Discarding should be done in user space. Bug: 194730965 Signed-off-by: Clement Viel <clement.viel@qorvo.com> Change-Id: Idde5992f82dde4235f8c1e2f709d5c2bc4fc95f8
2021-08-11clear PLL lock bit when configuring rf UWBM-268Jean-Michel RIOT
Bug: 194303361 Change-Id: I8a65c0b00a96770c2439e504da082a1bd2a5c594 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11mac: do not propagate ARFE error upper than fproc layerClement Viel
When there are interferences between responder and initiator, some frames are being marked as "filtered frames" and accounted as error. This patch discard "filetered frames" errors. Bug: 192407649 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com> Change-Id: I8a11d0387188eb0309cf1a39f6da63cf5244c949
2021-08-11mac: fix timing issues for MCTT / new featureHabib BEL HAJ ALI
- In controller mode, prevent dtu resync between SP0 and RIM tx. - In controller mode, prevent dtu resync between SP0 and RIM rx. Bug: 192387172 Change-Id: Idc88fe615ea17e8d3362772d4ca0a4a3487d95f9 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11mac: add debug traces and mac enhancementClement Viel
- add support for on-demande scheduler - handle stop conditions and notifications - change time comparison - add frame type traces Bug: 191475744 Change-Id: I5f241b51eea26066acc4be1cc6a3147d53adbc8f Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11dw3000: add DGC LUT loaded by defaultClement Viel
Restore DGC values when waking up Bug: 192387172 Change-Id: I867d522ed620dde22cf1b1bb2c60104f40857f33 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11Error after modifying UWB-calibration.confJean-Michel RIOT
mac: add an error parameter on fproc access_done ops, refs UWB-1526 Bug: 190222674 Change-Id: I19a54d0ed63265724f3066e065fad9c04e3d6697 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11Custom definition of phase difference to AoA mappingJean-Michel RIOT
dw3000: add PDoA to AoA lookup tables, refs UWB-1236 mac: use the AoA value computed the driver, refs UWB-1236 Bug: 172565633 Change-Id: I4137fc0d905a5d4cf67b799c6bafc6a7ba2e1829 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11dw3000: keep coex gpio high during entire ranging roundJean-Michel RIOT
The WiFi coex GPIO is put high and down for RX/TX operation. But it is supposed to stay high for the entire ranging round duration. The `need_ranging_clock` and delay before next operation is used to change this behavior. closes UWB-1496 Bug: 171489641 Change-Id: I8fe2bfdb460aa12105280600f177d8c39897da65 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11dw3000: update DGC tables and force use of latest LUTsClément Viel
dw3000: add driver version Bug: 190093936 Change-Id: I2f937d2204cfd0b8504e7f0d370ad8cc5a0e17ff Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11dw3000: when not using PDoA, do not setup second antenna of the pairNicolas Schodet
This release patch the Fira Session without aoa by ensuring no gpio switch happen Bug: 191043702 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com> Change-Id: I393d03e75ab5c4d86b91cfc3bb77c973adbb3503
2021-08-11mac/fira: add traces of frame types in rx and tx, closes UWB-1590Jean-Michel RIOT
Bug: 190093936 Change-Id: I6f4e655b4e3c905773810968f449655796e97703 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-08-11dw3000: avoid unbalanced regulatorsJean-Michel RIOT
Bug: 192387172 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com> Change-Id: Iaa7374a69e008ee0da9e9c5c6dcc65e230153496
2021-08-11UWB Mobile stack UWB-P2-S4Jean-Michel RIOT
1. Features - NFCC/AP Cooperation with deep sleep activation for Fira & CCC using HAL interface. 2. Fixes: - UCI Fixes - RSSI Fixes - Add better FiRa ranging status - b/190093936 P0 Link budget with FIRa ranging degraded vs. uwb-core SS ranging - b/189842875 P1 UwbAddress returned in onReportReceived callback has a reversed byte order - b/190904704 P1 When devices are very close, reports wrong distance - b/191923060 P1 PDoA offset is not working correctly - b/191043702 P1 Antennas should not be switched when AoA is not desired (FIRa ranging) - Deep Sleep in CCC is not functional - Deep_Sleep Ranging fira DB (deep sleep enabled) vs Minilocate ou DB (deep_sleep disabled) is KO - SFD Timeout should be set according to frame configuration - Distance report goes wrong when two device is very close - PDoA offset not working correctly - FiRa : No PDoA while Rx, when no AoA is requested 3. Known Issues - Simple ranging start failing after a few seconds - Channel 9 does not work on C0 & D0 | - Deep_Sleep Ranging fira DB (deep sleep enabled) vs Minilocate ou DB (deep_sleep disabled) is KO - AoA not working correctly on production stack (GPIO 7) - AoA not working correctly on production stack (AoA noisy) - [Deep_sleep disabled] Simple ranging stops periodically for ~2s during session Bug: 192387172 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com> Change-Id: Ifd2c56a1184a348ffcc23eed63fddbff338e7aa8
2021-07-07Revert "UWB Mobile stack UWB-P2-S4"android-12.0.0_r0.9android-12.0.0_r0.8android-12.0.0_r0.17android-12.0.0_r0.16android-gs-raviole-5.10-android12-d1Thierry Strudel
This reverts commit 713ccd47900ecb22590e580f9407a5c9479b3062. Bug: 192387172 Signed-off-by: Thierry Strudel <tstrudel@google.com> Change-Id: Ie4caa26a98ae314ea7c4f8a288534a7ae3836967
2021-07-02UWB Mobile stack UWB-P2-S4Jean-Michel RIOT
1. Features - NFCC/AP Cooperation with deep sleep activation for Fira & CCC using HAL interface. 2. Fixes: - UCI Fixes - RSSI Fixes - Add better FiRa ranging status - b/190093936 P0 Link budget with FIRa ranging degraded vs. uwb-core SS ranging - b/189842875 P1 UwbAddress returned in onReportReceived callback has a reversed byte order - b/190904704 P1 When devices are very close, reports wrong distance - b/191923060 P1 PDoA offset is not working correctly - b/191043702 P1 Antennas should not be switched when AoA is not desired (FIRa ranging) - Deep Sleep in CCC is not functional - Deep_Sleep Ranging fira DB (deep sleep enabled) vs Minilocate ou DB (deep_sleep disabled) is KO - SFD Timeout should be set according to frame configuration - Distance report goes wrong when two device is very close - PDoA offset not working correctly - FiRa : No PDoA while Rx, when no AoA is requested 3. Known Issues - Simple ranging start failing after a few seconds - Channel 9 does not work on C0 & D0 | - Deep_Sleep Ranging fira DB (deep sleep enabled) vs Minilocate ou DB (deep_sleep disabled) is KO - AoA not working correctly on production stack (GPIO 7) - AoA not working correctly on production stack (AoA noisy) - [Deep_sleep disabled] Simple ranging stops periodically for ~2s during session BUG: 192387172 Change-Id: I342b4541433aebea6b426f7fd98efb73bdf4abf2 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>
2021-06-18googleTaskForce : eng build with more traces for PDoAMathieu Perrier
CI: artifacts Bug: 191350163 Signed-off-by: Mathieu Perrier <mathieu.perrier@qorvo.com> Change-Id: I8df6da98ada0e37d9e8b68944d98448fb2022701
2021-06-18dw3000: fix setting dw3000 pin to GPIOSaad Zouiten
fixing pins 0..3, 7 and 8 Bug: 190224513 Change-Id: Ie3a80685c23e213fb3e9c7ee7407928d7d5ee3e5 Signed-off-by: Jean-Michel RIOT <jean-michel.riot@qorvo.com>