[PATCH 1/7] staging: wfx: fix handling of MMIC error
From: Jérôme Pouiller As expected, when the device detect a MMIC error, it returns a specific status. However, it also strip IV from the frame (don't ask me why). So, with the current code, mac80211 detects a corrupted frame and it drops it before it handle the MMIC error. The expected behavior would be to detect MMIC error then to renegotiate the EAP session. So, this patch correctly informs mac80211 that IV is not available. So, mac80211 correctly takes into account the MMIC error. Signed-off-by: Jérôme Pouiller --- drivers/staging/wfx/data_rx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/wfx/data_rx.c b/drivers/staging/wfx/data_rx.c index fe111d0aab63..86781098edc0 100644 --- a/drivers/staging/wfx/data_rx.c +++ b/drivers/staging/wfx/data_rx.c @@ -41,7 +41,7 @@ void wfx_rx_cb(struct wfx_vif *wvif, memset(hdr, 0, sizeof(*hdr)); if (arg->status == HIF_STATUS_RX_FAIL_MIC) - hdr->flag |= RX_FLAG_MMIC_ERROR; + hdr->flag |= RX_FLAG_MMIC_ERROR | RX_FLAG_IV_STRIPPED; else if (arg->status) goto drop; -- 2.28.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 6/7] dt-bindings: staging: wfx: silabs,wfx yaml conversion
From: Jérôme Pouiller The device can be connected on SPI or on SDIO. The original file described the two options separately. So, most of the file had to be rewritten in order to match with the Yaml requirements. Some device requirements are still written in the comments since they cannot been expressed with the current scheme (e.g. reg must be set to 1 with SDIO, interrupt is mandatory with SPI, reset-gpio in SPI is replaced by mmc-pwrseq in SDIO, etc...). The examples provided have also been reworked in order to make dt_binding_check happy. Finally, also fix typo in the name of the file (siliabs instead of silabs) Signed-off-by: Jérôme Pouiller --- .../bindings/net/wireless/silabs,wfx.yaml | 125 ++ .../bindings/net/wireless/siliabs,wfx.txt | 96 -- 2 files changed, 125 insertions(+), 96 deletions(-) create mode 100644 drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/silabs,wfx.yaml delete mode 100644 drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/siliabs,wfx.txt diff --git a/drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/silabs,wfx.yaml b/drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/silabs,wfx.yaml new file mode 100644 index ..43b5630c0407 --- /dev/null +++ b/drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/silabs,wfx.yaml @@ -0,0 +1,125 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +# Copyright (c) 2020, Silicon Laboratories, Inc. +%YAML 1.2 +--- + +$id: http://devicetree.org/schemas/net/wireless/silabs,wfx.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Silicon Labs WFxxx devicetree bindings + +maintainers: + - Jérôme Pouiller + +description: + The WFxxx chip series can be connected via SPI or via SDIO. + + For SDIO':' + +The driver is able to detect a WFxxx chip on SDIO bus by matching its Vendor +ID and Product ID. However, driver will only provide limited features in +this case. Thus declaring WFxxx chip in device tree is recommended (and may +become mandatory in the future). + +In addition, it is recommended to declare a mmc-pwrseq on SDIO host above +WFx. Without it, you may encounter issues with warm boot. The mmc-pwrseq +should be compatible with mmc-pwrseq-simple. Please consult +Documentation/devicetree/bindings/mmc/mmc-pwrseq-simple.txt for more +information. + + For SPI':' + +In add of the properties below, please consult +Documentation/devicetree/bindings/spi/spi-controller.yaml for optional SPI +related properties. + + Note that in add of the properties below, the WFx driver also supports + `mac-address` and `local-mac-address` as described in + Documentation/devicetree/bindings/net/ethernet.txt + +properties: + compatible: +const: silabs,wf200 + reg: +description: + When used on SDIO bus, must be set to 1. When used on SPI bus, it is + the chip select address of the device as defined in the SPI devices + bindings. +maxItems: 1 + spi-max-frequency: +description: (SPI only) Maximum SPI clocking speed of device in Hz. +maxItems: 1 + interrupts: +description: The interrupt line. Triggers IRQ_TYPE_LEVEL_HIGH and + IRQ_TYPE_EDGE_RISING are both supported by the chip and the driver. When + SPI is used, this property is required. When SDIO is used, the "in-band" + interrupt provided by the SDIO bus is used unless an interrupt is defined + in the Device Tree. +maxItems: 1 + reset-gpios: +description: (SPI only) Phandle of gpio that will be used to reset chip + during probe. Without this property, you may encounter issues with warm + boot. (For legacy purpose, the gpio in inverted when compatible == + "silabs,wfx-spi") + + For SDIO, the reset gpio should declared using a mmc-pwrseq. +maxItems: 1 + wakeup-gpios: +description: Phandle of gpio that will be used to wake-up chip. Without this + property, driver will disable most of power saving features. +maxItems: 1 + config-file: +description: Use an alternative file as PDS. Default is `wf200.pds`. Only + necessary for development/debug purpose. +maxItems: 1 + +required: + - compatible + - reg + +examples: + - | +#include +#include + +spi0 { +#address-cells = <1>; +#size-cells = <0>; + +wfx@0 { +compatible = "silabs,wf200"; +pinctrl-names = "default"; +pinctrl-0 = <&wfx_irq &wfx_gpios>; +reg = <0>; +interrupts-extended = <&gpio 16 IRQ_TYPE_EDGE_RISING>; +wakeup-gpios = <&gpio 12 GPIO_ACTIVE_HIGH>; +reset-gpios = <&gpio 13 GPIO_ACTIVE_LOW>; +spi-max-frequency = <4200>; +}; +}; + + - | +#include +#include + +wfx_pwrseq: wfx_pwrseq { +compatible = "mmc-pwrseq-simple"; +pinctrl-names = "default
[PATCH 0/7] wfx: move out from the staging area
From: Jérôme Pouiller I think the wfx driver is now mature enough to be accepted in the drivers/net/wireless directory. There is still one item on the TODO list. It is an idea to improve the rate control in some particular cases[1]. However, the current performances of the driver seem to satisfy everyone. In add, the suggested change is large enough. So, I would prefer to implement it only if it really solves an issue. I think it is not an obstacle to move the driver out of the staging area. In order to comply with the last rules for the DT bindings, I have converted the documentation to yaml. I am moderately happy with the result. Especially, for the description of the binding. Any comments are welcome. The series also update the copyrights dates of the files. I don't know exactly how this kind of changes should be sent. It's a bit weird to change all the copyrights in one commit, but I do not see any better way. I also include a few fixes I have found these last weeks. [1] https://lore.kernel.org/lkml/3099559.gv3Q75KnN1@pc-42 Jérôme Pouiller (7): staging: wfx: fix handling of MMIC error staging: wfx: remove remaining code of 'secure link' feature staging: wfx: fix BA sessions for older firmwares staging: wfx: fix QoS priority for slow buses staging: wfx: update copyrights dates dt-bindings: staging: wfx: silabs,wfx yaml conversion wfx: move out from the staging area .../bindings/net/wireless/silabs,wfx.yaml | 125 ++ MAINTAINERS | 2 +- drivers/net/wireless/Kconfig | 1 + drivers/net/wireless/Makefile | 1 + drivers/net/wireless/silabs/Kconfig | 17 +++ drivers/net/wireless/silabs/Makefile | 3 + .../wireless/silabs}/wfx/Kconfig | 0 .../wireless/silabs}/wfx/Makefile | 0 .../{staging => net/wireless/silabs}/wfx/bh.c | 2 +- .../{staging => net/wireless/silabs}/wfx/bh.h | 2 +- .../wireless/silabs}/wfx/bus.h| 2 +- .../wireless/silabs}/wfx/bus_sdio.c | 2 +- .../wireless/silabs}/wfx/bus_spi.c| 2 +- .../wireless/silabs}/wfx/data_rx.c| 7 +- .../wireless/silabs}/wfx/data_rx.h| 2 +- .../wireless/silabs}/wfx/data_tx.c| 2 +- .../wireless/silabs}/wfx/data_tx.h| 2 +- .../wireless/silabs}/wfx/debug.c | 19 +-- .../wireless/silabs}/wfx/debug.h | 0 .../wireless/silabs}/wfx/fwio.c | 2 +- .../wireless/silabs}/wfx/fwio.h | 0 .../wireless/silabs}/wfx/hif_api_cmd.h| 2 +- .../wireless/silabs}/wfx/hif_api_general.h| 2 +- .../wireless/silabs}/wfx/hif_api_mib.h| 2 +- .../wireless/silabs}/wfx/hif_rx.c | 2 +- .../wireless/silabs}/wfx/hif_rx.h | 0 .../wireless/silabs}/wfx/hif_tx.c | 2 +- .../wireless/silabs}/wfx/hif_tx.h | 2 +- .../wireless/silabs}/wfx/hif_tx_mib.c | 2 +- .../wireless/silabs}/wfx/hif_tx_mib.h | 2 +- .../wireless/silabs}/wfx/hwio.c | 2 +- .../wireless/silabs}/wfx/hwio.h | 2 +- .../wireless/silabs}/wfx/key.c| 2 +- .../wireless/silabs}/wfx/key.h| 2 +- .../wireless/silabs}/wfx/main.c | 2 +- .../wireless/silabs}/wfx/main.h | 2 +- .../wireless/silabs}/wfx/queue.c | 16 ++- .../wireless/silabs}/wfx/queue.h | 3 +- .../wireless/silabs}/wfx/scan.c | 2 +- .../wireless/silabs}/wfx/scan.h | 2 +- .../wireless/silabs}/wfx/sta.c| 2 +- .../wireless/silabs}/wfx/sta.h| 2 +- .../wireless/silabs}/wfx/traces.h | 2 +- .../wireless/silabs}/wfx/wfx.h| 2 +- drivers/staging/Kconfig | 2 - drivers/staging/Makefile | 1 - .../bindings/net/wireless/siliabs,wfx.txt | 98 -- drivers/staging/wfx/TODO | 6 - 48 files changed, 198 insertions(+), 161 deletions(-) create mode 100644 Documentation/devicetree/bindings/net/wireless/silabs,wfx.yaml create mode 100644 drivers/net/wireless/silabs/Kconfig create mode 100644 drivers/net/wireless/silabs/Makefile rename drivers/{staging => net/wireless/silabs}/wfx/Kconfig (100%) rename drivers/{staging => net/wireless/silabs}/wfx/Makefile (100%) rename drivers/{staging => net/wireless/silabs}/wfx/bh.c (99%) rename drivers/{staging => net/wireless/silabs}/wfx/bh.h (92%) rename drivers/{staging => net/wireless/silabs}/wfx/bus.h (94%) rename drivers/{staging => net/wireless/silabs}/wfx/bus_sdio.c (99%) rename drivers/{staging => net/wireless/silabs}/wfx/bus_spi.c (99%) rename drivers/{staging => net/wireless/silabs}/wfx/data_rx.c (93%) rename drivers/{staging => net/wireless/silabs}/wfx/data_rx.h (86%) rename drivers/{staging =>
[PATCH 7/7] wfx: move out from the staging area
From: Jérôme Pouiller The wfx driver is now mature enough to leave the staging area. Signed-off-by: Jérôme Pouiller --- .../bindings/net/wireless/silabs,wfx.yaml | 0 MAINTAINERS | 2 +- drivers/net/wireless/Kconfig| 1 + drivers/net/wireless/Makefile | 1 + drivers/net/wireless/silabs/Kconfig | 17 + drivers/net/wireless/silabs/Makefile| 3 +++ .../wireless/silabs}/wfx/Kconfig| 0 .../wireless/silabs}/wfx/Makefile | 0 .../{staging => net/wireless/silabs}/wfx/bh.c | 0 .../{staging => net/wireless/silabs}/wfx/bh.h | 0 .../{staging => net/wireless/silabs}/wfx/bus.h | 0 .../wireless/silabs}/wfx/bus_sdio.c | 0 .../wireless/silabs}/wfx/bus_spi.c | 0 .../wireless/silabs}/wfx/data_rx.c | 0 .../wireless/silabs}/wfx/data_rx.h | 0 .../wireless/silabs}/wfx/data_tx.c | 0 .../wireless/silabs}/wfx/data_tx.h | 0 .../wireless/silabs}/wfx/debug.c| 0 .../wireless/silabs}/wfx/debug.h| 0 .../{staging => net/wireless/silabs}/wfx/fwio.c | 0 .../{staging => net/wireless/silabs}/wfx/fwio.h | 0 .../wireless/silabs}/wfx/hif_api_cmd.h | 0 .../wireless/silabs}/wfx/hif_api_general.h | 0 .../wireless/silabs}/wfx/hif_api_mib.h | 0 .../wireless/silabs}/wfx/hif_rx.c | 0 .../wireless/silabs}/wfx/hif_rx.h | 0 .../wireless/silabs}/wfx/hif_tx.c | 0 .../wireless/silabs}/wfx/hif_tx.h | 0 .../wireless/silabs}/wfx/hif_tx_mib.c | 0 .../wireless/silabs}/wfx/hif_tx_mib.h | 0 .../{staging => net/wireless/silabs}/wfx/hwio.c | 0 .../{staging => net/wireless/silabs}/wfx/hwio.h | 0 .../{staging => net/wireless/silabs}/wfx/key.c | 0 .../{staging => net/wireless/silabs}/wfx/key.h | 0 .../{staging => net/wireless/silabs}/wfx/main.c | 0 .../{staging => net/wireless/silabs}/wfx/main.h | 0 .../wireless/silabs}/wfx/queue.c| 0 .../wireless/silabs}/wfx/queue.h| 0 .../{staging => net/wireless/silabs}/wfx/scan.c | 0 .../{staging => net/wireless/silabs}/wfx/scan.h | 0 .../{staging => net/wireless/silabs}/wfx/sta.c | 0 .../{staging => net/wireless/silabs}/wfx/sta.h | 0 .../wireless/silabs}/wfx/traces.h | 0 .../{staging => net/wireless/silabs}/wfx/wfx.h | 0 drivers/staging/Kconfig | 2 -- drivers/staging/Makefile| 1 - drivers/staging/wfx/TODO| 6 -- 47 files changed, 23 insertions(+), 10 deletions(-) rename {drivers/staging/wfx/Documentation => Documentation}/devicetree/bindings/net/wireless/silabs,wfx.yaml (100%) create mode 100644 drivers/net/wireless/silabs/Kconfig create mode 100644 drivers/net/wireless/silabs/Makefile rename drivers/{staging => net/wireless/silabs}/wfx/Kconfig (100%) rename drivers/{staging => net/wireless/silabs}/wfx/Makefile (100%) rename drivers/{staging => net/wireless/silabs}/wfx/bh.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/bh.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/bus.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/bus_sdio.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/bus_spi.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/data_rx.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/data_rx.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/data_tx.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/data_tx.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/debug.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/debug.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/fwio.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/fwio.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_api_cmd.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_api_general.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_api_mib.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_rx.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_rx.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_tx.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_tx.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_tx_mib.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hif_tx_mib.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hwio.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/hwio.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/key.c (100%) rename drivers/{staging => net/wireless/silabs}/wfx/key.h (100%) rename drivers/{staging => net/wireless/silabs}/wfx/main.c (100%) rename
[PATCH 2/7] staging: wfx: remove remaining code of 'secure link' feature
From: Jérôme Pouiller Commit e8d607ce0c81 ("staging: wfx: drop 'secure link' feature") had removed the 'secure link' feature. However, a few lines of codes were yet here. Fixes: e8d607ce0c81 ("staging: wfx: drop 'secure link' feature") Signed-off-by: Jérôme Pouiller --- .../bindings/net/wireless/siliabs,wfx.txt | 2 -- drivers/staging/wfx/debug.c | 17 - 2 files changed, 19 deletions(-) diff --git a/drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/siliabs,wfx.txt b/drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/siliabs,wfx.txt index 17db67559f5e..db8d06fc4baa 100644 --- a/drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/siliabs,wfx.txt +++ b/drivers/staging/wfx/Documentation/devicetree/bindings/net/wireless/siliabs,wfx.txt @@ -90,8 +90,6 @@ Some properties are recognized either by SPI and SDIO versions: this property, driver will disable most of power saving features. - config-file: Use an alternative file as PDS. Default is `wf200.pds`. Only necessary for development/debug purpose. - - slk_key: String representing hexadecimal value of secure link key to use. - Must contains 64 hexadecimal digits. Not supported in current version. WFx driver also supports `mac-address` and `local-mac-address` as described in Documentation/devicetree/bindings/net/ethernet.txt diff --git a/drivers/staging/wfx/debug.c b/drivers/staging/wfx/debug.c index ae44ffb66e34..4bd5f9fa21a1 100644 --- a/drivers/staging/wfx/debug.c +++ b/drivers/staging/wfx/debug.c @@ -230,21 +230,6 @@ static const struct file_operations wfx_send_pds_fops = { .write = wfx_send_pds_write, }; -static ssize_t wfx_burn_slk_key_write(struct file *file, - const char __user *user_buf, - size_t count, loff_t *ppos) -{ - struct wfx_dev *wdev = file->private_data; - - dev_info(wdev->dev, "this driver does not support secure link\n"); - return -EINVAL; -} - -static const struct file_operations wfx_burn_slk_key_fops = { - .open = simple_open, - .write = wfx_burn_slk_key_write, -}; - struct dbgfs_hif_msg { struct wfx_dev *wdev; struct completion complete; @@ -366,8 +351,6 @@ int wfx_debug_init(struct wfx_dev *wdev) debugfs_create_file("tx_power_loop", 0444, d, wdev, &wfx_tx_power_loop_fops); debugfs_create_file("send_pds", 0200, d, wdev, &wfx_send_pds_fops); - debugfs_create_file("burn_slk_key", 0200, d, wdev, - &wfx_burn_slk_key_fops); debugfs_create_file("send_hif_msg", 0600, d, wdev, &wfx_send_hif_msg_fops); debugfs_create_file("ps_timeout", 0600, d, wdev, &wfx_ps_timeout_fops); -- 2.28.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 4/7] staging: wfx: fix QoS priority for slow buses
From: Jérôme Pouiller The device is in charge of respecting the QoS constraints. The driver have to ensure that all the queues contain data and the device choose the right queue to send. The things starts to be more difficult when the bandwidth of the bus is lower than the bandwidth of the WiFi. The device quickly sends the frames of the highest priority queue. Then, it starts to send frames from a lower priority queue. Though, there are still some high priority frames waiting in the driver. To work around this problem, this patch add some priorities to each queue. The weigh of the queue was (roughly) calculated experimentally by checking the speed ratio of each queue when the bus does not limit the traffic: - Be/Bk -> 20Mbps/10Mbps - Vi/Be -> 36Mbps/180Kbps - Vo/Be -> 35Mbps/600Kbps - Vi/Vo -> 24Mbps/12Mbps So, if we fix the weigh of the Background to 1, the weight of Best Effort should be 2. The weight of Video should be 116. However, since there is only 32 queues, it make no sense to use a value greater than 64[1]. And finally, the weight of the Voice is set to 128. [1] Because of this approximation, with very slow bus, we can still observe frame starvation when we measure the speed ratio of Vi/Be. It is around 35Mbps/1Mbps (instead of 36Mbps/180Kbps). However, it is still in accepted error range. Signed-off-by: Jérôme Pouiller --- drivers/staging/wfx/queue.c | 14 -- drivers/staging/wfx/queue.h | 1 + 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/drivers/staging/wfx/queue.c b/drivers/staging/wfx/queue.c index 6e3159165143..55b801a02959 100644 --- a/drivers/staging/wfx/queue.c +++ b/drivers/staging/wfx/queue.c @@ -60,11 +60,16 @@ void wfx_tx_lock_flush(struct wfx_dev *wdev) void wfx_tx_queues_init(struct wfx_vif *wvif) { + // The device is in charge to respect the details of the QoS parameters. + // The driver just ensure that it roughtly respect the priorities to + // avoid any shortage. + const int priorities[IEEE80211_NUM_ACS] = { 1, 2, 64, 128 }; int i; for (i = 0; i < IEEE80211_NUM_ACS; ++i) { skb_queue_head_init(&wvif->tx_queue[i].normal); skb_queue_head_init(&wvif->tx_queue[i].cab); + wvif->tx_queue[i].priority = priorities[i]; } } @@ -219,6 +224,11 @@ bool wfx_tx_queues_has_cab(struct wfx_vif *wvif) return false; } +static int wfx_tx_queue_get_weight(struct wfx_queue *queue) +{ + return atomic_read(&queue->pending_frames) * queue->priority; +} + static struct sk_buff *wfx_tx_queues_get_skb(struct wfx_dev *wdev) { struct wfx_queue *queues[IEEE80211_NUM_ACS * ARRAY_SIZE(wdev->vif)]; @@ -234,8 +244,8 @@ static struct sk_buff *wfx_tx_queues_get_skb(struct wfx_dev *wdev) WARN_ON(num_queues >= ARRAY_SIZE(queues)); queues[num_queues] = &wvif->tx_queue[i]; for (j = num_queues; j > 0; j--) - if (atomic_read(&queues[j]->pending_frames) < - atomic_read(&queues[j - 1]->pending_frames)) + if (wfx_tx_queue_get_weight(queues[j]) < + wfx_tx_queue_get_weight(queues[j - 1])) swap(queues[j - 1], queues[j]); num_queues++; } diff --git a/drivers/staging/wfx/queue.h b/drivers/staging/wfx/queue.h index 22d7c936907f..2695c10d6a22 100644 --- a/drivers/staging/wfx/queue.h +++ b/drivers/staging/wfx/queue.h @@ -18,6 +18,7 @@ struct wfx_queue { struct sk_buff_head normal; struct sk_buff_head cab; // Content After (DTIM) Beacon atomic_tpending_frames; + int priority; }; void wfx_tx_lock(struct wfx_dev *wdev); -- 2.28.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 3/7] staging: wfx: fix BA sessions for older firmwares
From: Jérôme Pouiller Firmwares with API < 3.6 do not forward DELBA requests. Thus, when a Block Ack session is restarted, the reordering buffer is not flushed and the received sequence number is not contiguous. Therefore, mac80211 starts to wait some missing frames that it will never receive. This patch disables the reordering buffer for old firmware. It is harmless when the network is unencrypted. When the network is encrypted, the non-contiguous frames will be thrown away by the TKIP/CCMP replay protection. So, the user will observe some packet loss with UDP and performance drop with TCP. Fixes: e5da5fbd7741 ("staging: wfx: fix CCMP/TKIP replay protection") Signed-off-by: Jérôme Pouiller --- drivers/staging/wfx/data_rx.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/staging/wfx/data_rx.c b/drivers/staging/wfx/data_rx.c index 86781098edc0..3822a22b9fe3 100644 --- a/drivers/staging/wfx/data_rx.c +++ b/drivers/staging/wfx/data_rx.c @@ -17,6 +17,9 @@ static void wfx_rx_handle_ba(struct wfx_vif *wvif, struct ieee80211_mgmt *mgmt) { int params, tid; + if (wfx_api_older_than(wvif->wdev, 3, 6)) + return; + switch (mgmt->u.action.u.addba_req.action_code) { case WLAN_ACTION_ADDBA_REQ: params = le16_to_cpu(mgmt->u.action.u.addba_req.capab); -- 2.28.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 5/7] staging: wfx: update copyrights dates
From: Jérôme Pouiller Most of the files have been modified in 2020, so update the copyright notices. Signed-off-by: Jérôme Pouiller --- drivers/staging/wfx/bh.c | 2 +- drivers/staging/wfx/bh.h | 2 +- drivers/staging/wfx/bus.h | 2 +- drivers/staging/wfx/bus_sdio.c| 2 +- drivers/staging/wfx/bus_spi.c | 2 +- drivers/staging/wfx/data_rx.c | 2 +- drivers/staging/wfx/data_rx.h | 2 +- drivers/staging/wfx/data_tx.c | 2 +- drivers/staging/wfx/data_tx.h | 2 +- drivers/staging/wfx/debug.c | 2 +- drivers/staging/wfx/fwio.c| 2 +- drivers/staging/wfx/hif_api_cmd.h | 2 +- drivers/staging/wfx/hif_api_general.h | 2 +- drivers/staging/wfx/hif_api_mib.h | 2 +- drivers/staging/wfx/hif_rx.c | 2 +- drivers/staging/wfx/hif_tx.c | 2 +- drivers/staging/wfx/hif_tx.h | 2 +- drivers/staging/wfx/hif_tx_mib.c | 2 +- drivers/staging/wfx/hif_tx_mib.h | 2 +- drivers/staging/wfx/hwio.c| 2 +- drivers/staging/wfx/hwio.h| 2 +- drivers/staging/wfx/key.c | 2 +- drivers/staging/wfx/key.h | 2 +- drivers/staging/wfx/main.c| 2 +- drivers/staging/wfx/main.h| 2 +- drivers/staging/wfx/queue.c | 2 +- drivers/staging/wfx/queue.h | 2 +- drivers/staging/wfx/scan.c| 2 +- drivers/staging/wfx/scan.h| 2 +- drivers/staging/wfx/sta.c | 2 +- drivers/staging/wfx/sta.h | 2 +- drivers/staging/wfx/traces.h | 2 +- drivers/staging/wfx/wfx.h | 2 +- 33 files changed, 33 insertions(+), 33 deletions(-) diff --git a/drivers/staging/wfx/bh.c b/drivers/staging/wfx/bh.c index 72da2f4af49f..586b769c0446 100644 --- a/drivers/staging/wfx/bh.c +++ b/drivers/staging/wfx/bh.c @@ -2,7 +2,7 @@ /* * Interrupt bottom half (BH). * - * Copyright (c) 2017-2019, Silicon Laboratories, Inc. + * Copyright (c) 2017-2020, Silicon Laboratories, Inc. * Copyright (c) 2010, ST-Ericsson */ #include diff --git a/drivers/staging/wfx/bh.h b/drivers/staging/wfx/bh.h index 4b73437869e1..78c49329e22a 100644 --- a/drivers/staging/wfx/bh.h +++ b/drivers/staging/wfx/bh.h @@ -2,7 +2,7 @@ /* * Interrupt bottom half. * - * Copyright (c) 2017-2019, Silicon Laboratories, Inc. + * Copyright (c) 2017-2020, Silicon Laboratories, Inc. * Copyright (c) 2010, ST-Ericsson */ #ifndef WFX_BH_H diff --git a/drivers/staging/wfx/bus.h b/drivers/staging/wfx/bus.h index 0370b6c59863..ca04b3da6204 100644 --- a/drivers/staging/wfx/bus.h +++ b/drivers/staging/wfx/bus.h @@ -2,7 +2,7 @@ /* * Common bus abstraction layer. * - * Copyright (c) 2017-2018, Silicon Laboratories, Inc. + * Copyright (c) 2017-2020, Silicon Laboratories, Inc. * Copyright (c) 2010, ST-Ericsson */ #ifndef WFX_BUS_H diff --git a/drivers/staging/wfx/bus_sdio.c b/drivers/staging/wfx/bus_sdio.c index 496bfc8bbacc..e06d7e1ebe9c 100644 --- a/drivers/staging/wfx/bus_sdio.c +++ b/drivers/staging/wfx/bus_sdio.c @@ -2,7 +2,7 @@ /* * SDIO interface. * - * Copyright (c) 2017-2019, Silicon Laboratories, Inc. + * Copyright (c) 2017-2020, Silicon Laboratories, Inc. * Copyright (c) 2010, ST-Ericsson */ #include diff --git a/drivers/staging/wfx/bus_spi.c b/drivers/staging/wfx/bus_spi.c index d19c0478e8be..a99125d1a30d 100644 --- a/drivers/staging/wfx/bus_spi.c +++ b/drivers/staging/wfx/bus_spi.c @@ -2,7 +2,7 @@ /* * SPI interface. * - * Copyright (c) 2017-2019, Silicon Laboratories, Inc. + * Copyright (c) 2017-2020, Silicon Laboratories, Inc. * Copyright (c) 2011, Sagrad Inc. * Copyright (c) 2010, ST-Ericsson */ diff --git a/drivers/staging/wfx/data_rx.c b/drivers/staging/wfx/data_rx.c index 3822a22b9fe3..385f2d42a0e2 100644 --- a/drivers/staging/wfx/data_rx.c +++ b/drivers/staging/wfx/data_rx.c @@ -2,7 +2,7 @@ /* * Datapath implementation. * - * Copyright (c) 2017-2019, Silicon Laboratories, Inc. + * Copyright (c) 2017-2020, Silicon Laboratories, Inc. * Copyright (c) 2010, ST-Ericsson */ #include diff --git a/drivers/staging/wfx/data_rx.h b/drivers/staging/wfx/data_rx.h index 125dbfc1f875..4c0da37f2084 100644 --- a/drivers/staging/wfx/data_rx.h +++ b/drivers/staging/wfx/data_rx.h @@ -2,7 +2,7 @@ /* * Datapath implementation. * - * Copyright (c) 2017-2019, Silicon Laboratories, Inc. + * Copyright (c) 2017-2020, Silicon Laboratories, Inc. * Copyright (c) 2010, ST-Ericsson */ #ifndef WFX_DATA_RX_H diff --git a/drivers/staging/wfx/data_tx.c b/drivers/staging/wfx/data_tx.c index e2fb770e98fc..b4d5dd3d2d23 100644 --- a/drivers/staging/wfx/data_tx.c +++ b/drivers/staging/wfx/data_tx.c @@ -2,7 +2,7 @@ /* * Datapath implementation. * - * Copyright (c) 2017-2019, Silicon Laboratories, Inc. + * Copyright (c) 2017-2020, Silicon Laboratories, Inc. * Copyright (c) 2010, ST-Ericsson */ #include diff --git a/drivers/staging/wfx/data_tx.h b/drivers/staging/wfx/dat
Re: [PATCH 0/7] wfx: move out from the staging area
On Wed, Oct 07, 2020 at 12:19:36PM +0200, Jerome Pouiller wrote: > From: Jérôme Pouiller > > I think the wfx driver is now mature enough to be accepted in the > drivers/net/wireless directory. > > There is still one item on the TODO list. It is an idea to improve the rate > control in some particular cases[1]. However, the current performances of the > driver seem to satisfy everyone. In add, the suggested change is large enough. > So, I would prefer to implement it only if it really solves an issue. I think > it > is not an obstacle to move the driver out of the staging area. > > In order to comply with the last rules for the DT bindings, I have converted > the > documentation to yaml. I am moderately happy with the result. Especially, for > the description of the binding. Any comments are welcome. > > The series also update the copyrights dates of the files. I don't know exactly > how this kind of changes should be sent. It's a bit weird to change all the > copyrights in one commit, but I do not see any better way. > > I also include a few fixes I have found these last weeks. > > [1] https://lore.kernel.org/lkml/3099559.gv3Q75KnN1@pc-42 I'll take the first 6 patches here, the last one you should work with the wireless maintainers to get reviewed. Maybe that might want to wait until after 5.10-rc1 is out, with all of these changes in it, making it an easier move. thanks, greg k-h ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] media: atomisp: stop compiling compat_ioctl32 code
This is one of the last remaining users of compat_alloc_user_space() and copy_in_user(), which are in the process of getting removed. As of commit 57e6b6f2303e ("media: atomisp_fops.c: disable atomisp_compat_ioctl32"), nothing in this file is actually getting used as the only reference has been stubbed out. Do the same thing here and stub out the implementation as well while leaving it in place, with a comment explaining the problem. Alternatively, the entire file could just be removed, since anyone willing to restore the functionality can equally well just look up the contents in the git history if needed. Cc: Christoph Hellwig Cc: Sakari Ailus Cc: Hans Verkuil Signed-off-by: Arnd Bergmann --- .../staging/media/atomisp/pci/atomisp_compat_ioctl32.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c b/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c index e5553df5bad4..bc6ef902a520 100644 --- a/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c +++ b/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c @@ -15,7 +15,15 @@ * * */ -#ifdef CONFIG_COMPAT + +/* + * The compat code is disabled for now, as compat_alloc_user_space() + * is in the process of getting removed. The compat_ioctl implementation + * here was already disabled in commit 57e6b6f2303e ("media: atomisp_fops.c: + * disable atomisp_compat_ioctl32"), so this is all dead code, but it + * is left for reference as long as something like it is in fact needed. + */ +#if 0 /* #ifdef CONFIG_COMPAT */ #include #include -- 2.27.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH] media: atomisp: stop compiling compat_ioctl32 code
On Wed, Oct 07, 2020 at 04:16:39PM +0200, Arnd Bergmann wrote: > Alternatively, the entire file could just be removed, since anyone > willing to restore the functionality can equally well just look up > the contents in the git history if needed. I suspect that is the right thing. Note that given that the driver is only in staging anyway, the right thing to do would be to change the ioctl ABI to be more compat friendly to start with. ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH v2] media: atomisp: remove compat_ioctl32 code
This is one of the last remaining users of compat_alloc_user_space() and copy_in_user(), which are in the process of getting removed. As of commit 57e6b6f2303e ("media: atomisp_fops.c: disable atomisp_compat_ioctl32"), nothing in this file is actually getting used as the only reference has been stubbed out. Remove the entire file -- anyone willing to restore the functionality can equally well just look up the contents in the git history if needed. Cc: Sakari Ailus Cc: Hans Verkuil Suggested-by: Christoph Hellwig Signed-off-by: Arnd Bergmann --- This is the alternative approach for the patch, removing the already dead code instead of just not compiling it. --- drivers/staging/media/atomisp/Makefile|1 - drivers/staging/media/atomisp/TODO|5 + .../atomisp/pci/atomisp_compat_ioctl32.c | 1202 - .../staging/media/atomisp/pci/atomisp_fops.c |8 +- 4 files changed, 8 insertions(+), 1208 deletions(-) delete mode 100644 drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c diff --git a/drivers/staging/media/atomisp/Makefile b/drivers/staging/media/atomisp/Makefile index 1dfad0dd02d0..3bbd4bf4408c 100644 --- a/drivers/staging/media/atomisp/Makefile +++ b/drivers/staging/media/atomisp/Makefile @@ -16,7 +16,6 @@ atomisp-objs += \ pci/atomisp_acc.o \ pci/atomisp_cmd.o \ pci/atomisp_compat_css20.o \ - pci/atomisp_compat_ioctl32.o \ pci/atomisp_csi2.o \ pci/atomisp_drvfs.o \ pci/atomisp_file.o \ diff --git a/drivers/staging/media/atomisp/TODO b/drivers/staging/media/atomisp/TODO index 6987bb2d32cf..2d1ef9eb262a 100644 --- a/drivers/staging/media/atomisp/TODO +++ b/drivers/staging/media/atomisp/TODO @@ -120,6 +120,11 @@ TODO for this driver until the other work is done, as there will be a lot of code churn until this driver becomes functional again. +16. Fix private ioctls to not need a compat_ioctl handler for running +32-bit tasks. The compat code has been removed because of bugs, +and should not be needed for modern drivers. Fixing this properly +unfortunately means an incompatible ABI change. + Limitations === diff --git a/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c b/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c deleted file mode 100644 index e5553df5bad4.. --- a/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c +++ /dev/null @@ -1,1202 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -/* - * Support for Intel Camera Imaging ISP subsystem. - * - * Copyright (c) 2013 Intel Corporation. All Rights Reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License version - * 2 as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * - */ -#ifdef CONFIG_COMPAT -#include - -#include - -#include "atomisp_internal.h" -#include "atomisp_compat.h" -#include "atomisp_ioctl.h" -#include "atomisp_compat_ioctl32.h" - -/* Macros borrowed from v4l2-compat-ioctl32.c */ - -#define get_user_cast(__x, __ptr) \ -({ \ - get_user(__x, (typeof(*__ptr) __user *)(__ptr));\ -}) - -#define put_user_force(__x, __ptr) \ -({ \ - put_user((typeof(*__x) __force *)(__x), __ptr); \ -}) - -/* Use the same argument order as copy_in_user */ -#define assign_in_user(to, from) \ -({ \ - typeof(*from) __assign_tmp; \ - \ - get_user_cast(__assign_tmp, from) || put_user(__assign_tmp, to);\ -}) - -static int get_atomisp_histogram32(struct atomisp_histogram __user *kp, - struct atomisp_histogram32 __user *up) -{ - compat_uptr_t tmp; - - if (!access_ok(up, sizeof(struct atomisp_histogram32)) || - assign_in_user(&kp->num_elements, &up->num_elements) || - get_user(tmp, &up->data) || - put_user(compat_ptr(tmp), &kp->data)) - return -EFAULT; - - return 0; -} - -static int put_atomisp_histogram32(struct atomisp_histogram __user *kp, - struct atomisp_histogram32 __user *up) -{ - void __user *tmp; - - if (!access_ok(up, sizeof(struct atomisp_histogram32)) || - assign_in_user(&up->num_elements, &kp->num_elements) || -
Re: [PATCH] media: atomisp: stop compiling compat_ioctl32 code
On Wed, Oct 7, 2020 at 4:18 PM Christoph Hellwig wrote: > > On Wed, Oct 07, 2020 at 04:16:39PM +0200, Arnd Bergmann wrote: > > Alternatively, the entire file could just be removed, since anyone > > willing to restore the functionality can equally well just look up > > the contents in the git history if needed. > > I suspect that is the right thing. Note that given that the driver > is only in staging anyway, the right thing to do would be to change > the ioctl ABI to be more compat friendly to start with. Ok, I sent that as v2 now. I wonder how many of those 56 ioctl commands in the driver are actually used in practice. Is there a public repository for the matching user space? Is it required to even use the driver or is it otherwise compatible with normal v4l2 applications? Arnd ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH v2] media: atomisp: remove compat_ioctl32 code
On Wed, Oct 07, 2020 at 05:34:15PM +0200, Arnd Bergmann wrote: > This is one of the last remaining users of compat_alloc_user_space() > and copy_in_user(), which are in the process of getting removed. > > As of commit 57e6b6f2303e ("media: atomisp_fops.c: disable > atomisp_compat_ioctl32"), nothing in this file is actually getting used > as the only reference has been stubbed out. > > Remove the entire file -- anyone willing to restore the functionality > can equally well just look up the contents in the git history if needed. Good one! Reviewed-by: Andy Shevchenko > Cc: Sakari Ailus > Cc: Hans Verkuil > Suggested-by: Christoph Hellwig > Signed-off-by: Arnd Bergmann > --- > This is the alternative approach for the patch, removing the already > dead code instead of just not compiling it. > --- > drivers/staging/media/atomisp/Makefile|1 - > drivers/staging/media/atomisp/TODO|5 + > .../atomisp/pci/atomisp_compat_ioctl32.c | 1202 - > .../staging/media/atomisp/pci/atomisp_fops.c |8 +- > 4 files changed, 8 insertions(+), 1208 deletions(-) > delete mode 100644 drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c > > diff --git a/drivers/staging/media/atomisp/Makefile > b/drivers/staging/media/atomisp/Makefile > index 1dfad0dd02d0..3bbd4bf4408c 100644 > --- a/drivers/staging/media/atomisp/Makefile > +++ b/drivers/staging/media/atomisp/Makefile > @@ -16,7 +16,6 @@ atomisp-objs += \ > pci/atomisp_acc.o \ > pci/atomisp_cmd.o \ > pci/atomisp_compat_css20.o \ > - pci/atomisp_compat_ioctl32.o \ > pci/atomisp_csi2.o \ > pci/atomisp_drvfs.o \ > pci/atomisp_file.o \ > diff --git a/drivers/staging/media/atomisp/TODO > b/drivers/staging/media/atomisp/TODO > index 6987bb2d32cf..2d1ef9eb262a 100644 > --- a/drivers/staging/media/atomisp/TODO > +++ b/drivers/staging/media/atomisp/TODO > @@ -120,6 +120,11 @@ TODO > for this driver until the other work is done, as there will be a lot > of code churn until this driver becomes functional again. > > +16. Fix private ioctls to not need a compat_ioctl handler for running > +32-bit tasks. The compat code has been removed because of bugs, > +and should not be needed for modern drivers. Fixing this properly > +unfortunately means an incompatible ABI change. > + > Limitations > === > > diff --git a/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c > b/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c > deleted file mode 100644 > index e5553df5bad4.. > --- a/drivers/staging/media/atomisp/pci/atomisp_compat_ioctl32.c > +++ /dev/null > @@ -1,1202 +0,0 @@ > -// SPDX-License-Identifier: GPL-2.0 > -/* > - * Support for Intel Camera Imaging ISP subsystem. > - * > - * Copyright (c) 2013 Intel Corporation. All Rights Reserved. > - * > - * This program is free software; you can redistribute it and/or > - * modify it under the terms of the GNU General Public License version > - * 2 as published by the Free Software Foundation. > - * > - * This program is distributed in the hope that it will be useful, > - * but WITHOUT ANY WARRANTY; without even the implied warranty of > - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > - * GNU General Public License for more details. > - * > - * > - */ > -#ifdef CONFIG_COMPAT > -#include > - > -#include > - > -#include "atomisp_internal.h" > -#include "atomisp_compat.h" > -#include "atomisp_ioctl.h" > -#include "atomisp_compat_ioctl32.h" > - > -/* Macros borrowed from v4l2-compat-ioctl32.c */ > - > -#define get_user_cast(__x, __ptr)\ > -({ \ > - get_user(__x, (typeof(*__ptr) __user *)(__ptr));\ > -}) > - > -#define put_user_force(__x, __ptr) \ > -({ \ > - put_user((typeof(*__x) __force *)(__x), __ptr); \ > -}) > - > -/* Use the same argument order as copy_in_user */ > -#define assign_in_user(to, from) \ > -({ \ > - typeof(*from) __assign_tmp; \ > - \ > - get_user_cast(__assign_tmp, from) || put_user(__assign_tmp, to);\ > -}) > - > -static int get_atomisp_histogram32(struct atomisp_histogram __user *kp, > -struct atomisp_histogram32 __user *up) > -{ > - compat_uptr_t tmp; > - > - if (!access_ok(up, sizeof(struct atomisp_histogram32)) || > - assign_in_user(&kp->num_elements, &up->num_elements) || > - get_user(tmp, &up->data) || > - put_user(compat_ptr(tmp), &kp->data)) > - return -EFAULT; > - > - return 0; > -} > - > -static int put_atomisp_
Најмила кај господарот
Најмила кај господарот Јас сум 68-годишна жена, која страда од продолжен карцином на дојка, од сите медицински индикации, мојата состојба навистина се влоши и очигледно е дека можеби нема да живеам повеќе од шест месеци како резултат на брзиот раст и болката што се јавува кај неа. Мојот сопруг почина неколку години наназад и нашите долги години брак не беа благословени со ниту едно дете, по неговата смрт го наследив целото негово богатство. Доаѓам кај вас откако се помолив за тоа, подготвен сум да донирам сума од 2, 300, 000 евра за помош на сиромашните, сиромашните и помалку привилегираните меѓу вашите собранија / општество. Забележете дека овој фонд е депониран во банка каде што работеше мојот сопруг. Appreciateе ценам ако обрнете внимание на моето барање за пропагирање на масажата на кралството, ќе ви дадам повеќе детали за тоа како да постапите. Благодарам Г-ѓа Мерилин Роберт ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH v2 07/11] drivers/android/binder: convert stats, transaction_log to counter_atomic32
On Tue, Oct 06, 2020 at 02:44:38PM -0600, Shuah Khan wrote: > counter_atomic* is introduced to be used when a variable is used as > a simple counter and doesn't guard object lifetimes. This clearly > differentiates atomic_t usages that guard object lifetimes. > > counter_atomic* variables will wrap around to 0 when it overflows and > should not be used to guard resource lifetimes, device usage and > open counts that control state changes, and pm states. > > stats tracks per-process binder statistics. Unsure if there is a chance > of this overflowing, other than stats getting reset to 0. Convert it to > use counter_atomic. > > binder_transaction_log:cur is used to keep track of the current log entry > location. Overflow is handled in the code. Since it is used as a > counter, convert it to use counter_atomic32. > > This conversion doesn't change the overflow wrap around behavior. > > Reviewed-by: Joel Fernandes (Google) > Signed-off-by: Shuah Khan Yup, seems to be stats-only. Reviewed-by: Kees Cook -- Kees Cook ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH v2 00/11] Introduce Simple atomic counters
On Tue, Oct 06, 2020 at 02:44:31PM -0600, Shuah Khan wrote: > -- Addressed Kees's and Joel's comments: >1. Removed dec_return interfaces (Patch 1/11) >2. Removed counter_simple interfaces to be added later with changes > to drivers that use them (if any) (Patch 1/11) >3. Comment and Changelogs updates to Patch 2/11 Thanks! > Kees, if this series is good, would you like to take this through your > tree or would you like to take this through mine? I think it's very close! I've sent reviews. Why don't you take this tree for now? (Originally I thought this was going through Greg's tree since it was touching a lot of drivers.) -- Kees Cook ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[staging:staging-testing] BUILD SUCCESS 76c3bdd67d27289b9e407113821eab2a70bbcca6
ul2_defconfig powerpc cm5200_defconfig sh sh7770_generic_defconfig arm spitz_defconfig arm iop32x_defconfig sh r7780mp_defconfig microblaze defconfig mips ip22_defconfig ia64 allmodconfig ia64defconfig ia64 allyesconfig m68k allmodconfig m68kdefconfig m68k allyesconfig nios2 defconfig arc allyesconfig nds32 allnoconfig c6x allyesconfig nds32 defconfig nios2allyesconfig cskydefconfig alpha defconfig h8300allyesconfig arc defconfig sh allmodconfig xtensa allyesconfig parisc defconfig s390 allyesconfig parisc allyesconfig s390defconfig i386 allyesconfig sparcallyesconfig sparc defconfig i386defconfig mips allyesconfig mips allmodconfig powerpc allyesconfig powerpc allmodconfig powerpc allnoconfig x86_64 randconfig-a004-20201006 x86_64 randconfig-a002-20201006 x86_64 randconfig-a001-20201006 x86_64 randconfig-a005-20201006 x86_64 randconfig-a003-20201006 x86_64 randconfig-a006-20201006 i386 randconfig-a006-20201005 i386 randconfig-a005-20201005 i386 randconfig-a001-20201005 i386 randconfig-a004-20201005 i386 randconfig-a003-20201005 i386 randconfig-a002-20201005 i386 randconfig-a006-20201008 i386 randconfig-a005-20201008 i386 randconfig-a001-20201008 i386 randconfig-a004-20201008 i386 randconfig-a002-20201008 i386 randconfig-a003-20201008 i386 randconfig-a006-20201007 i386 randconfig-a005-20201007 i386 randconfig-a001-20201007 i386 randconfig-a004-20201007 i386 randconfig-a003-20201007 i386 randconfig-a002-20201007 x86_64 randconfig-a012-20201007 x86_64 randconfig-a015-20201007 x86_64 randconfig-a014-20201007 x86_64 randconfig-a013-20201007 x86_64 randconfig-a011-20201007 x86_64 randconfig-a016-20201007 x86_64 randconfig-a012-20201005 x86_64 randconfig-a015-20201005 x86_64 randconfig-a014-20201005 x86_64 randconfig-a013-20201005 x86_64 randconfig-a011-20201005 x86_64 randconfig-a016-20201005 i386 randconfig-a015-20201008 i386 randconfig-a013-20201008 i386 randconfig-a014-20201008 i386 randconfig-a016-20201008 i386 randconfig-a011-20201008 i386 randconfig-a012-20201008 i386 randconfig-a014-20201005 i386 randconfig-a015-20201005 i386 randconfig-a013-20201005 i386 randconfig-a016-20201005 i386 randconfig-a011-20201005 i386 randconfig-a012-20201005 x86_64 randconfig-a004-20201008 x86_64 randconfig-a003-20201008 x86_64 randconfig-a005-20201008 x86_64 randconfig-a001-20201008 x86_64 randconfig-a002-20201008 x86_64 randconfig-a006-20201008 riscvnommu_k210_defconfig riscvallyesconfig riscvnommu_virt_defconfig riscv defconfig riscv rv32_defconfig riscvallmodconfig x86_64 rhel x86_64 allyesconfig x86_64rhel-7.6-kselftests x86_64 defconfig x86_64 rhel-8.3 x86_64 kexec clang tested configs: x86_64 randconfig-a004-20201007 x86_64 randconfig-a002-20201007 x86_64 randconfig-a001-20201007 x86_64
RE: [PATCH v6 5/8] clk: clock-wizard: Add support for fractional support
Quoting Shubhrajyoti Datta (2020-09-23 23:23:11) > > > -Original Message- > > From: Stephen Boyd > > Sent: Tuesday, September 22, 2020 2:48 AM > > > +} > > > + > > > +static long clk_wzrd_round_rate_f(struct clk_hw *hw, unsigned long > > rate, > > > + unsigned long *prate) { > > > + return rate; > > > > Can every rate be supported? This function is supposed to tell the clk > > framework what rate will be achieved if we call clk_set_rate() with 'rate' > > passed to this function. Almost always returning 'rate' is not the case. > > > > We can support rate upto 3 decimal places to prevent truncation here we are > Returning rate. So all rates can be supported? > > > @@ -413,8 +543,18 @@ static int clk_wzrd_probe(struct platform_device > > *pdev) > > > ret = -EINVAL; > > > goto err_rm_int_clks; > > > } > > > - clk_wzrd->clkout[i] = > > > clk_wzrd_register_divider(&pdev->dev, > > > - > > > clkout_name, > > > + if (!i) > > > + clk_wzrd->clkout[i] = clk_wzrd_register_divf > > > + (&pdev->dev, clkout_name, > > > + clk_name, 0, > > > + clk_wzrd->base, (WZRD_CLK_CFG_REG(2) + i > > > * 12), > > > + WZRD_CLKOUT_DIVIDE_SHIFT, > > > + WZRD_CLKOUT_DIVIDE_WIDTH, > > > + CLK_DIVIDER_ONE_BASED | > > CLK_DIVIDER_ALLOW_ZERO, > > > + NULL, &clkwzrd_lock); > > > + else > > > + clk_wzrd->clkout[i] = clk_wzrd_register_divider > > > + (&pdev->dev, clkout_name, > > > clk_name, 0, > > > clk_wzrd->base, (WZRD_CLK_CFG_REG(2) + i > > > * 12), > > > WZRD_CLKOUT_DIVIDE_SHIFT, > > > > > > > I wonder if a do-while loop with flags set to ONE_BASED and ALLOW_ZERO > > could work and then flags gets overwritten to be just DIVIDE_SHIFT? Then > > we don't have to duplicate the registration line. > > I did not understand this comment in one case I am registering for the > fractional operations > In another we are using the integral operations Yes and the case depends on the value of i being zero or non-zero. So can it be converted to a do while loop and the if condition dropped? ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel