<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/drivers/net/wireless/atmel/atmel.c, branch linux-6.2.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.</subtitle>
<id>https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-6.2.y</id>
<link rel='self' href='https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-6.2.y'/>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/'/>
<updated>2022-11-01T10:30:22Z</updated>
<entry>
<title>wifi: atmel: Fix atmel_private_handler array size</title>
<updated>2022-11-01T10:30:22Z</updated>
<author>
<name>Kees Cook</name>
<email>keescook@chromium.org</email>
</author>
<published>2022-10-18T02:37:59Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=8b860466b137d77cb95907cacb1c9443712e6f6b'/>
<id>urn:sha1:8b860466b137d77cb95907cacb1c9443712e6f6b</id>
<content type='text'>
Fix the atmel_private_handler to correctly sized (1 element) again. (I
should have checked the data segment for differences.) This had no
behavioral impact (no private callbacks), but it made a very large
zero-filled array.

Cc: Simon Kelley &lt;simon@thekelleys.org.uk&gt;
Cc: Kalle Valo &lt;kvalo@kernel.org&gt;
Cc: "David S. Miller" &lt;davem@davemloft.net&gt;
Cc: Eric Dumazet &lt;edumazet@google.com&gt;
Cc: Jakub Kicinski &lt;kuba@kernel.org&gt;
Cc: Paolo Abeni &lt;pabeni@redhat.com&gt;
Cc: linux-wireless@vger.kernel.org
Cc: netdev@vger.kernel.org
Fixes: 8af9d4068e86 ("wifi: atmel: Avoid clashing function prototypes")
Signed-off-by: Kees Cook &lt;keescook@chromium.org&gt;
Signed-off-by: Kalle Valo &lt;kvalo@kernel.org&gt;
Link: https://lore.kernel.org/r/20221018023732.never.700-kees@kernel.org
</content>
</entry>
<entry>
<title>wifi: atmel: Avoid clashing function prototypes</title>
<updated>2022-10-05T07:50:50Z</updated>
<author>
<name>Kees Cook</name>
<email>keescook@chromium.org</email>
</author>
<published>2022-10-02T03:24:28Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=8af9d4068e86dd5c3221ee495ec09537c7fb458b'/>
<id>urn:sha1:8af9d4068e86dd5c3221ee495ec09537c7fb458b</id>
<content type='text'>
When built with Control Flow Integrity, function prototypes between
caller and function declaration must match. These mismatches are visible
at compile time with the new -Wcast-function-type-strict in Clang[1].

Of the 1549 warnings found, 188 come from the atmel driver. For example:

drivers/net/wireless/atmel/atmel.c:2518:2: warning: cast from 'int (*)(struct net_device *, struct iw_request_info *, void *, char *)' to 'iw_handler' (aka 'int (*)(struct net_device *, struct iw_request_info *, union iwreq_data *, char *)') converts to incompatible function type [-Wcast-function-type-strict]
        (iw_handler) atmel_config_commit,       /* SIOCSIWCOMMIT */
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

The atmel Wireless Extension handler callbacks (iw_handler) use a union
for the data argument. Actually use the union and perform explicit
member selection in the function body instead of having a function
prototype mismatch. There are no resulting binary differences.

This patch is a cleanup based on Brad Spengler/PaX Team's modifications
to the atmel driver in their last public patch of grsecurity/PaX based
on my understanding of the code. Changes or omissions from the original
code are mine and don't reflect the original grsecurity/PaX code.

[1] https://reviews.llvm.org/D134831

Cc: Simon Kelley &lt;simon@thekelleys.org.uk&gt;
Cc: Kalle Valo &lt;kvalo@kernel.org&gt;
Cc: "David S. Miller" &lt;davem@davemloft.net&gt;
Cc: Eric Dumazet &lt;edumazet@google.com&gt;
Cc: Jakub Kicinski &lt;kuba@kernel.org&gt;
Cc: Paolo Abeni &lt;pabeni@redhat.com&gt;
Cc: linux-wireless@vger.kernel.org
Cc: netdev@vger.kernel.org
Signed-off-by: Kees Cook &lt;keescook@chromium.org&gt;
Signed-off-by: Kalle Valo &lt;kvalo@kernel.org&gt;
Link: https://lore.kernel.org/r/20221002032428.4091540-1-keescook@chromium.org
</content>
</entry>
<entry>
<title>wifi: move from strlcpy with unused retval to strscpy</title>
<updated>2022-09-02T08:47:22Z</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa+renesas@sang-engineering.com</email>
</author>
<published>2022-08-30T20:14:53Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=bf99f11df4de45fcba6f6c441b411a16bccaccf6'/>
<id>urn:sha1:bf99f11df4de45fcba6f6c441b411a16bccaccf6</id>
<content type='text'>
Follow the advice of the below link and prefer 'strscpy' in this
subsystem. Conversion is 1:1 because the return value is not used.
Generated by a coccinelle script.

Link: https://lore.kernel.org/r/CAHk-=wgfRnXz0W3D37d01q3JFkr_i_uTL=V6A6G1oUZcprmknw@mail.gmail.com/
Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@kernel.org&gt;
Link: https://lore.kernel.org/r/20220830201457.7984-2-wsa+renesas@sang-engineering.com
</content>
</entry>
<entry>
<title>wifi: atmel: fix repeated words in comments</title>
<updated>2022-07-18T12:06:59Z</updated>
<author>
<name>Jilin Yuan</name>
<email>yuanjilin@cdjrlc.com</email>
</author>
<published>2022-07-09T13:26:37Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=15978ea38d79d6c376be672117dfcf646a24d1fe'/>
<id>urn:sha1:15978ea38d79d6c376be672117dfcf646a24d1fe</id>
<content type='text'>
Delete the redundant word 'long'.

Signed-off-by: Jilin Yuan &lt;yuanjilin@cdjrlc.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@kernel.org&gt;
Link: https://lore.kernel.org/r/20220709132637.16717-1-yuanjilin@cdjrlc.com
</content>
</entry>
<entry>
<title>atmel: use eth_hw_addr_set()</title>
<updated>2021-10-20T09:39:44Z</updated>
<author>
<name>Jakub Kicinski</name>
<email>kuba@kernel.org</email>
</author>
<published>2021-10-18T23:50:12Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=251277af9c4fccc8969dbd56acebf11825d2c69c'/>
<id>urn:sha1:251277af9c4fccc8969dbd56acebf11825d2c69c</id>
<content type='text'>
Commit 406f42fa0d3c ("net-next: When a bond have a massive amount
of VLANs...") introduced a rbtree for faster Ethernet address look
up. To maintain netdev-&gt;dev_addr in this tree we need to make all
the writes to it got through appropriate helpers.

Use a buffer on the stack. Note that atmel_get_mib() is a wrapper
around atmel_copy_to_host(). For the to device direction we just
need to make sure functions respect argument being cost.

Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20211018235021.1279697-7-kuba@kernel.org
</content>
</entry>
<entry>
<title>wireless: use eth_hw_addr_set() for dev-&gt;addr_len cases</title>
<updated>2021-10-20T09:39:43Z</updated>
<author>
<name>Jakub Kicinski</name>
<email>kuba@kernel.org</email>
</author>
<published>2021-10-18T23:50:09Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=8fac27fbc80ecdb22c2dd001e9bb0684eed55c01'/>
<id>urn:sha1:8fac27fbc80ecdb22c2dd001e9bb0684eed55c01</id>
<content type='text'>
Convert all WiFi drivers from memcpy(... dev-&gt;addr_len)
to eth_hw_addr_set():

  @@
  expression dev, np;
  @@
  - memcpy(dev-&gt;dev_addr, np, dev-&gt;addr_len)
  + eth_hw_addr_set(dev, np)

Manually checked the netdevs are allocated with alloc_etherdev(),
so dev-&gt;addr_len must be equal to ETH_ALEN.

Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20211018235021.1279697-4-kuba@kernel.org
</content>
</entry>
<entry>
<title>wireless: use eth_hw_addr_set()</title>
<updated>2021-10-20T09:39:42Z</updated>
<author>
<name>Jakub Kicinski</name>
<email>kuba@kernel.org</email>
</author>
<published>2021-10-18T23:50:07Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=708884e7f7f3adb00ddb32d1c1a772d30bf86747'/>
<id>urn:sha1:708884e7f7f3adb00ddb32d1c1a772d30bf86747</id>
<content type='text'>
Convert all WiFi drivers from memcpy(... ETH_ADDR)
to eth_hw_addr_set():

  @@
  expression dev, np;
  @@
  - memcpy(dev-&gt;dev_addr, np, ETH_ALEN)
  + eth_hw_addr_set(dev, np)

Signed-off-by: Jakub Kicinski &lt;kuba@kernel.org&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20211018235021.1279697-2-kuba@kernel.org
</content>
</entry>
<entry>
<title>module: remove never implemented MODULE_SUPPORTED_DEVICE</title>
<updated>2021-03-17T20:16:18Z</updated>
<author>
<name>Leon Romanovsky</name>
<email>leonro@nvidia.com</email>
</author>
<published>2021-03-17T10:45:47Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=6417f03132a6952cd17ddd8eaddbac92b61b17e0'/>
<id>urn:sha1:6417f03132a6952cd17ddd8eaddbac92b61b17e0</id>
<content type='text'>
MODULE_SUPPORTED_DEVICE was added in pre-git era and never was
implemented. We can safely remove it, because the kernel has grown
to have many more reliable mechanisms to determine if device is
supported or not.

Signed-off-by: Leon Romanovsky &lt;leonro@nvidia.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>atmel: Use fallthrough pseudo-keyword</title>
<updated>2020-08-27T13:09:19Z</updated>
<author>
<name>Gustavo A. R. Silva</name>
<email>gustavoars@kernel.org</email>
</author>
<published>2020-08-21T06:53:55Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=9ccac12996ec8b7a8dc05573d6dad8cc32b70b04'/>
<id>urn:sha1:9ccac12996ec8b7a8dc05573d6dad8cc32b70b04</id>
<content type='text'>
Replace the existing /* fall through */ comments and its variants with
the new pseudo-keyword macro fallthrough[1].

[1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through

Signed-off-by: Gustavo A. R. Silva &lt;gustavoars@kernel.org&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20200821065355.GA25808@embeddedor
</content>
</entry>
<entry>
<title>atmel: Demote non-kerneldoc header to standard comment block</title>
<updated>2020-08-27T12:15:22Z</updated>
<author>
<name>Lee Jones</name>
<email>lee.jones@linaro.org</email>
</author>
<published>2020-08-14T11:39:08Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=68fd3030ad67f57d4b421ef9fd2a48cf24ba3b35'/>
<id>urn:sha1:68fd3030ad67f57d4b421ef9fd2a48cf24ba3b35</id>
<content type='text'>
Fixes the following W=1 kernel build warning(s):

 drivers/net/wireless/atmel/atmel.c:4232: warning: Cannot understand     This file is part of net.russotto.AtmelMACFW, hereto referred to

Cc: Simon Kelley &lt;simon@thekelleys.org.uk&gt;
Cc: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Cc: "David S. Miller" &lt;davem@davemloft.net&gt;
Cc: Jakub Kicinski &lt;kuba@kernel.org&gt;
Cc: linux-wireless@vger.kernel.org
Cc: netdev@vger.kernel.org
Signed-off-by: Lee Jones &lt;lee.jones@linaro.org&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Link: https://lore.kernel.org/r/20200814113933.1903438-6-lee.jones@linaro.org
</content>
</entry>
</feed>
