linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] wireless/nl80211.c: fix uninitialized variable
@ 2021-03-29 16:30 Alaa Emad
  2021-03-29 18:20 ` Greg KH
  0 siblings, 1 reply; 4+ messages in thread
From: Alaa Emad @ 2021-03-29 16:30 UTC (permalink / raw)
  To: johannes, davem, kuba
  Cc: gregkh, linux-wireless, netdev, linux-kernel, syzkaller,
	Alaa Emad, syzbot+72b99dcf4607e8c770f3

Reported-by: syzbot+72b99dcf4607e8c770f3@syzkaller.appspotmail.com
Signed-off-by: Alaa Emad <alaaemadhossney.ae@gmail.com>
---
 net/wireless/nl80211.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 775d0c4d86c3..b87ab67ad33d 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -210,7 +210,7 @@ static int validate_beacon_head(const struct nlattr *attr,
 	const struct element *elem;
 	const struct ieee80211_mgmt *mgmt = (void *)data;
 	bool s1g_bcn = ieee80211_is_s1g_beacon(mgmt->frame_control);
-	unsigned int fixedlen, hdrlen;
+	unsigned int fixedlen = 0, hdrlen;
 
 	if (s1g_bcn) {
 		fixedlen = offsetof(struct ieee80211_ext,
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] wireless/nl80211.c: fix uninitialized variable
  2021-03-29 16:30 [PATCH] wireless/nl80211.c: fix uninitialized variable Alaa Emad
@ 2021-03-29 18:20 ` Greg KH
       [not found]   ` <CAM1DhOgA9DDaGSGFxKgXBONopoo4rLJZheK2jzW_BK-mJrNZKQ@mail.gmail.com>
  0 siblings, 1 reply; 4+ messages in thread
From: Greg KH @ 2021-03-29 18:20 UTC (permalink / raw)
  To: Alaa Emad
  Cc: johannes, davem, kuba, linux-wireless, netdev, linux-kernel,
	syzkaller, syzbot+72b99dcf4607e8c770f3

On Mon, Mar 29, 2021 at 06:30:36PM +0200, Alaa Emad wrote:
> Reported-by: syzbot+72b99dcf4607e8c770f3@syzkaller.appspotmail.com
> Signed-off-by: Alaa Emad <alaaemadhossney.ae@gmail.com>

You need to provide some changelog text here, I know I can not take
patches without that, maybe the wireless maintainer is more flexible :)

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] wireless/nl80211.c: fix uninitialized variable
       [not found]   ` <CAM1DhOgA9DDaGSGFxKgXBONopoo4rLJZheK2jzW_BK-mJrNZKQ@mail.gmail.com>
@ 2021-03-29 18:58     ` Greg KH
       [not found]       ` <CAM1DhOjWgN_0GVBeX+pf+9mk_ysaN9pF4agAFUNEkzhxpFR4=w@mail.gmail.com>
  0 siblings, 1 reply; 4+ messages in thread
From: Greg KH @ 2021-03-29 18:58 UTC (permalink / raw)
  To: Alaa Emad
  Cc: johannes, davem, kuba, linux-wireless, netdev, LKML, syzkaller,
	syzbot+72b99dcf4607e8c770f3

On Mon, Mar 29, 2021 at 08:41:38PM +0200, Alaa Emad wrote:
> On Mon, 29 Mar 2021 at 20:20, Greg KH <gregkh@linuxfoundation.org> wrote:
> 
> > On Mon, Mar 29, 2021 at 06:30:36PM +0200, Alaa Emad wrote:
> > > Reported-by: syzbot+72b99dcf4607e8c770f3@syzkaller.appspotmail.com
> > > Signed-off-by: Alaa Emad <alaaemadhossney.ae@gmail.com>
> >
> > You need to provide some changelog text here, I know I can not take
> > patches without that, maybe the wireless maintainer is more flexible :)
> >
>  you mean explain what i did , right?

Yes, explain why this change is needed.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] wireless/nl80211.c: fix uninitialized variable
       [not found]       ` <CAM1DhOjWgN_0GVBeX+pf+9mk_ysaN9pF4agAFUNEkzhxpFR4=w@mail.gmail.com>
@ 2021-03-30 12:48         ` Pavel Skripkin
  0 siblings, 0 replies; 4+ messages in thread
From: Pavel Skripkin @ 2021-03-30 12:48 UTC (permalink / raw)
  To: Alaa Emad, Greg KH
  Cc: johannes, davem, kuba, linux-wireless, netdev, LKML, syzkaller,
	syzbot+72b99dcf4607e8c770f3

Hi!

On Tue, 2021-03-30 at 14:42 +0200, Alaa Emad wrote:
> 
> 
> On Mon, 29 Mar 2021 at 20:58, Greg KH <gregkh@linuxfoundation.org>
> wrote:
> > On Mon, Mar 29, 2021 at 08:41:38PM +0200, Alaa Emad wrote:
> > > On Mon, 29 Mar 2021 at 20:20, Greg KH <gregkh@linuxfoundation.org>
> > wrote:
> > > 
> > > > On Mon, Mar 29, 2021 at 06:30:36PM +0200, Alaa Emad wrote:
> > > > > Reported-by:
> > syzbot+72b99dcf4607e8c770f3@syzkaller.appspotmail.com
> > > > > Signed-off-by: Alaa Emad <alaaemadhossney.ae@gmail.com>
> > > > 
> > > > You need to provide some changelog text here, I know I can not
> > take
> > > > patches without that, maybe the wireless maintainer is more
> > flexible :)
> > > > 
> > >   you mean explain what i did , right?
> > 
> > Yes, explain why this change is needed.
> > 
> 
> 
>   
>   This change fix  KMSAN uninit-value in net/wireless/nl80211.c:225 ,
> That because of `fixedlen` variable uninitialized. 
>    So I initialized it by zero because the code assigned value to it
> after that and doesn't depend on any stored value in it . 

You should add this message to the patch, not just write it to
maintainer.

I think, this link might be
useful https://www.kernel.org/doc/html/v4.17/process/submitting-patches.html

> > 
> > thanks,
> > 
> > greg k-h
> > 
> 
> 
> 
> Thanks ,
> Alaa
> -- 
> You received this message because you are subscribed to the Google
> Groups "syzkaller" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to syzkaller+unsubscribe@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/syzkaller/CAM1DhOjWgN_0GVBeX%2Bpf%2B9mk_ysaN9pF4agAFUNEkzhxpFR4%3Dw%40mail.gmail.com
> .

With regards,
Pavel Skripkin



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-03-30 12:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-29 16:30 [PATCH] wireless/nl80211.c: fix uninitialized variable Alaa Emad
2021-03-29 18:20 ` Greg KH
     [not found]   ` <CAM1DhOgA9DDaGSGFxKgXBONopoo4rLJZheK2jzW_BK-mJrNZKQ@mail.gmail.com>
2021-03-29 18:58     ` Greg KH
     [not found]       ` <CAM1DhOjWgN_0GVBeX+pf+9mk_ysaN9pF4agAFUNEkzhxpFR4=w@mail.gmail.com>
2021-03-30 12:48         ` Pavel Skripkin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).