Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: wfx: explain the purpose of wfx_send_pds()

On first look, the goal of wfx_send_pds() is not obvious. A small
explanation is welcomed.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20210913130203.1903622-31-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Jérôme Pouiller and committed by
Greg Kroah-Hartman
c382d79a b262f38c

+14 -1
+14 -1
drivers/staging/wfx/main.c
··· 163 163 return false; 164 164 } 165 165 166 - /* NOTE: wfx_send_pds() destroy buf */ 166 + /* The device needs data about the antenna configuration. This information in 167 + * provided by PDS (Platform Data Set, this is the wording used in WF200 168 + * documentation) files. For hardware integrators, the full process to create 169 + * PDS files is described here: 170 + * https:github.com/SiliconLabs/wfx-firmware/blob/master/PDS/README.md 171 + * 172 + * So this function aims to send PDS to the device. However, the PDS file is 173 + * often bigger than Rx buffers of the chip, so it has to be sent in multiple 174 + * parts. 175 + * 176 + * In add, the PDS data cannot be split anywhere. The PDS files contains tree 177 + * structures. Braces are used to enter/leave a level of the tree (in a JSON 178 + * fashion). PDS files can only been split between root nodes. 179 + */ 167 180 int wfx_send_pds(struct wfx_dev *wdev, u8 *buf, size_t len) 168 181 { 169 182 int ret;