From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Felipe Balbi <balbi@kernel.org>, linux-usb@vger.kernel.org
Cc: Greg KH <greg@kroah.com>, Joel Stanley <joel@jms.id.au>,
Andrew Jeffery <andrew@aj.id.au>
Subject: [v6,2/2] usb/gadget: Add driver for Aspeed SoC virtual hub
Date: Sun, 25 Mar 2018 12:25:17 +1100 [thread overview]
Message-ID: <1521941117.16434.384.camel@kernel.crashing.org> (raw)
On Sat, 2018-03-24 at 12:19 +1100, Benjamin Herrenschmidt wrote:
> > In function ‘memcpy’,
> > inlined from ‘ast_vhub_rep_desc’ at drivers/usb/gadget/udc/aspeed-vhub/hub.c:276:2:
> > ./include/linux/string.h:341:4: error: call to ‘__read_overflow2’ declared with attribute error: detected read beyond size of object passed as 2nd parameter
> > __read_overflow2();
>
> That's really odd... some new gcc thing ? I don't understand where the
> overflow would occur... Do you see anything ? Unless my brain is acting
> up, there is no overflow and gcc is bogus:
>
> I just hand counted the size of the 3 possible structures "desc" can
> point to and compared to the constants used for the size, and it all
> fits.
>
> Unfortunately, I can't seem to reproduce with the version of cross
> compiler I'm using here, so I'm not sure what construct to use to
> make gcc stop erroneously barfing...
So I've tried with 2 ARM cross compilers (gcc 6.3.0 built by buildroot
and 7.2.1 from Fedora 27) and couldn't reproduce this.
I also tried an x86_64 build with that driver with 7.3.1 20180130 (from
Fedora 27) and here too, couldn't reproduce the problem.
What toolchain precisely are you using ? It really smells like a gcc
bug to me...
Cheers,
Ben.
---
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next reply other threads:[~2018-03-25 1:25 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-25 1:25 Benjamin Herrenschmidt [this message]
-- strict thread matches above, loose matches on Subject: below --
2018-03-26 0:25 [v6,2/2] usb/gadget: Add driver for Aspeed SoC virtual hub Benjamin Herrenschmidt
2018-03-24 1:19 Benjamin Herrenschmidt
2018-03-23 7:54 Felipe Balbi
2018-03-23 2:44 Benjamin Herrenschmidt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1521941117.16434.384.camel@kernel.crashing.org \
--to=benh@kernel.crashing.org \
--cc=andrew@aj.id.au \
--cc=balbi@kernel.org \
--cc=greg@kroah.com \
--cc=joel@jms.id.au \
--cc=linux-usb@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).