<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-dev/drivers/staging/rtl8192u, branch master</title>
<subtitle>Linux kernel development work - see feature branches</subtitle>
<id>https://git.zx2c4.com/linux-dev/atom/drivers/staging/rtl8192u?h=master</id>
<link rel='self' href='https://git.zx2c4.com/linux-dev/atom/drivers/staging/rtl8192u?h=master'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/'/>
<updated>2022-09-24T11:05:33Z</updated>
<entry>
<title>staging: rtl8192u: Fix return type of ieee80211_xmit</title>
<updated>2022-09-24T11:05:33Z</updated>
<author>
<name>Nathan Huckleberry</name>
<email>nhuck@google.com</email>
</author>
<published>2022-09-14T21:07:50Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=2851349ac351010a2649e0ff86a1e3d68fe5d683'/>
<id>urn:sha1:2851349ac351010a2649e0ff86a1e3d68fe5d683</id>
<content type='text'>
The ndo_start_xmit field in net_device_ops is expected to be of type
netdev_tx_t (*ndo_start_xmit)(struct sk_buff *skb, struct net_device *dev).

The mismatched return type breaks forward edge kCFI since the underlying
function definition does not match the function hook definition.

The return type of ieee80211_xmit should be changed from int to
netdev_tx_t.

Link: https://github.com/ClangBuiltLinux/linux/issues/1703
Cc: llvm@lists.linux.dev
Reported-by: Dan Carpenter &lt;error27@gmail.com&gt;
Reviewed-by: Nathan Chancellor &lt;nathan@kernel.org&gt;
Signed-off-by: Nathan Huckleberry &lt;nhuck@google.com&gt;
Link: https://lore.kernel.org/r/20220914210750.423048-1-nhuck@google.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: fix rmmod warn when device is renamed</title>
<updated>2022-08-16T13:13:27Z</updated>
<author>
<name>Tong Zhang</name>
<email>ztong0001@gmail.com</email>
</author>
<published>2022-07-30T03:33:24Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=7b84ab85b12648bc27016088776bbd075e022be3'/>
<id>urn:sha1:7b84ab85b12648bc27016088776bbd075e022be3</id>
<content type='text'>
This driver creates 4 debug files under [devname] folder. The devname
could be wlan0 initially, however it could be renamed later to e.g.
enx00e04c00000. This will cause problem during debug file teardown since
it uses netdev-&gt;name, which is no longer wlan0. To solve this problem,
add a notifier to handle device renaming. Also note that we cannot
simply do debugfs_lookup to find out old dentry since by the time the
notifier is called, netdev-&gt;name is already changed to new name.

Reported-by: Zheyu Ma &lt;zheyuma97@gmail.com&gt;
Tested-by: Zheyu Ma &lt;zheyuma97@gmail.com&gt;
Reviewed-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Tong Zhang &lt;ztong0001@gmail.com&gt;
Link: https://lore.kernel.org/r/20220730033335.74153-5-ztong0001@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: move debug files to debugfs</title>
<updated>2022-08-16T13:13:27Z</updated>
<author>
<name>Tong Zhang</name>
<email>ztong0001@gmail.com</email>
</author>
<published>2022-07-30T03:33:23Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=c5682c05b26215592faa97deeec896454179169b'/>
<id>urn:sha1:c5682c05b26215592faa97deeec896454179169b</id>
<content type='text'>
There are 4 debug files created under /proc/net/[Devname].
Due to this is purely for debuging as files are created read only,
move this to debugfs like other NIC drivers do instead of using procfs.
The directory structure will be like the following

  /sys/kernel/debug/r8192u_usb/wlan0/stats-rx
  /sys/kernel/debug/r8192u_usb/wlan0/stats-rx
  /sys/kernel/debug/r8192u_usb/wlan0/stats-ap
  /sys/kernel/debug/r8192u_usb/wlan0/registers

This is also to prepare for address rmmod warn issue.

Reviewed-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Tong Zhang &lt;ztong0001@gmail.com&gt;
Link: https://lore.kernel.org/r/20220730033335.74153-4-ztong0001@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: remove unnecessary cast</title>
<updated>2022-08-16T13:13:27Z</updated>
<author>
<name>Tong Zhang</name>
<email>ztong0001@gmail.com</email>
</author>
<published>2022-07-30T03:33:22Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=626d28e9becadb8e9b7cc66ec93184b671edf175'/>
<id>urn:sha1:626d28e9becadb8e9b7cc66ec93184b671edf175</id>
<content type='text'>
Cast is not needed when calling ieee80211_priv, so remove them.
No functional change in this commit.

Signed-off-by: Tong Zhang &lt;ztong0001@gmail.com&gt;
Link: https://lore.kernel.org/r/20220730033335.74153-3-ztong0001@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: move debug stuff to its own file</title>
<updated>2022-08-16T13:13:27Z</updated>
<author>
<name>Tong Zhang</name>
<email>ztong0001@gmail.com</email>
</author>
<published>2022-07-30T03:33:21Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=2faa312bc01b4930220fa2c4f4cbaebf3f25ea07'/>
<id>urn:sha1:2faa312bc01b4930220fa2c4f4cbaebf3f25ea07</id>
<content type='text'>
This is to prepare for moving them to debugfs and fix rmmod warn issue
when wlan0 is renamed to something else.

Reviewed-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Tong Zhang &lt;ztong0001@gmail.com&gt;
Link: https://lore.kernel.org/r/20220730033335.74153-2-ztong0001@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: Fix sleep in atomic context bug in dm_fsync_timer_callback</title>
<updated>2022-07-11T08:05:35Z</updated>
<author>
<name>Duoming Zhou</name>
<email>duoming@zju.edu.cn</email>
</author>
<published>2022-07-10T10:30:02Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=6a0c054930d554ad8f8044ef1fc856d9da391c81'/>
<id>urn:sha1:6a0c054930d554ad8f8044ef1fc856d9da391c81</id>
<content type='text'>
There are sleep in atomic context bugs when dm_fsync_timer_callback is
executing. The root cause is that the memory allocation functions with
GFP_KERNEL or GFP_NOIO parameters are called in dm_fsync_timer_callback
which is a timer handler. The call paths that could trigger bugs are
shown below:

    (interrupt context)
dm_fsync_timer_callback
  write_nic_byte
    kzalloc(sizeof(data), GFP_KERNEL); //may sleep
    usb_control_msg
      kmalloc(.., GFP_NOIO); //may sleep
  write_nic_dword
    kzalloc(sizeof(data), GFP_KERNEL); //may sleep
    usb_control_msg
      kmalloc(.., GFP_NOIO); //may sleep

This patch uses delayed work to replace timer and moves the operations
that may sleep into the delayed work in order to mitigate bugs.

Fixes: 8fc8598e61f6 ("Staging: Added Realtek rtl8192u driver to staging")
Signed-off-by: Duoming Zhou &lt;duoming@zju.edu.cn&gt;
Link: https://lore.kernel.org/r/20220710103002.63283-1-duoming@zju.edu.cn
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: Fix syntax errors in comments</title>
<updated>2022-06-06T06:02:57Z</updated>
<author>
<name>Xiang wangx</name>
<email>wangxiang@cdjrlc.com</email>
</author>
<published>2022-06-03T13:07:02Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=d2a4bc3d979fda657729a5ea6b8dc6c6978fabb2'/>
<id>urn:sha1:d2a4bc3d979fda657729a5ea6b8dc6c6978fabb2</id>
<content type='text'>
Delete the redundant word 'tx'.

Signed-off-by: Xiang wangx &lt;wangxiang@cdjrlc.com&gt;
Link: https://lore.kernel.org/r/20220603130702.6926-1-wangxiang@cdjrlc.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: remove null check after call container_of()</title>
<updated>2022-05-19T15:42:53Z</updated>
<author>
<name>Haowen Bai</name>
<email>baihaowen@meizu.com</email>
</author>
<published>2022-05-16T10:22:12Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=902d75058129aa33c899e08c97d4f5cda8d047eb'/>
<id>urn:sha1:902d75058129aa33c899e08c97d4f5cda8d047eb</id>
<content type='text'>
container_of() will never return NULL, so remove useless code.

Signed-off-by: Haowen Bai &lt;baihaowen@meizu.com&gt;
Link: https://lore.kernel.org/r/1652696533-18011-1-git-send-email-baihaowen@meizu.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: make const array queuetopipe const, reduces object code size</title>
<updated>2022-05-19T15:40:44Z</updated>
<author>
<name>Colin Ian King</name>
<email>colin.i.king@gmail.com</email>
</author>
<published>2022-05-07T18:34:14Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=20e7ac6f74bc1142f9f9ca0fa46a13d6c3b4cebb'/>
<id>urn:sha1:20e7ac6f74bc1142f9f9ca0fa46a13d6c3b4cebb</id>
<content type='text'>
Don't populate the const array queuetopipe on the stack, instead make it
static.  Also makes the object code smaller.

Signed-off-by: Colin Ian King &lt;colin.i.king@gmail.com&gt;
Link: https://lore.kernel.org/r/20220507183414.26633-1-colin.i.king@gmail.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: rtl8192u: Fix signedness bug in ieee80211_check_auth_response()</title>
<updated>2022-04-22T14:48:31Z</updated>
<author>
<name>Haowen Bai</name>
<email>baihaowen@meizu.com</email>
</author>
<published>2022-04-22T02:10:35Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=89c734e1980259e439f3c57f1e63729dc0038740'/>
<id>urn:sha1:89c734e1980259e439f3c57f1e63729dc0038740</id>
<content type='text'>
The ieee80211_check_auth_response() function has a signedness bug because
it's a declared as a u16 but it return -ENOMEM.  When you look at it more
closely it returns a mix of error codes including 0xcafe, -ENOMEM, and
a-&gt;status which is WLAN_STATUS_NOT_SUPPORTED_AUTH_ALG.  This is a mess.

Clean it up to just return standard kernel error codes.  We can print
out the a-&gt;status before returning a regular error code.  The printks
in the caller need to be adjusted as well.

Signed-off-by: Haowen Bai &lt;baihaowen@meizu.com&gt;
Link: https://lore.kernel.org/r/1650593435-9017-1-git-send-email-baihaowen@meizu.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
</feed>
