From: John David Anglin <dave.anglin@bell.net>
To: James Bottomley <James.Bottomley@HansenPartnership.com>,
Helge Deller <deller@gmx.de>
Cc: linux-parisc List <linux-parisc@vger.kernel.org>
Subject: Re: Aw: [PATCH v3] parisc: Change L1_CACHE_BYTES to 16
Date: Thu, 22 Oct 2015 10:53:28 -0400 [thread overview]
Message-ID: <5628F868.3040105@bell.net> (raw)
In-Reply-To: <1445524549.2207.1.camel@HansenPartnership.com>
On 2015-10-22 10:35 AM, James Bottomley wrote:
> On Thu, 2015-10-22 at 13:53 +0200, Helge Deller wrote:
>>>> Betreff: [PATCH v3] parisc: Change L1_CACHE_BYTES to 16
>>>> The latest version changes L1_CACHE_BYTES to 16 bytes and doesn't =
adjust SMP_CACHE_BYTES as
>>>> per James suggestion
>>> This patch sadly breaks build on Linux kernel git head:
>>>
>>> In file included from /home/cvs/LINUX/git-kernel/linux-2.6/net/core=
/dev.c:92:0:
>>> /net/core/dev.c: In function =E2=80=98expand_xps_map=E2=80=99:
>>> /include/linux/netdevice.h:721:27: warning: overflow in implicit co=
nstant conversion [-Woverflow]
>>> #define XPS_MIN_MAP_ALLOC ((L1_CACHE_BYTES - sizeof(struct xps_ma=
p)) \
>>> /net/core/dev.c:1972:18: note: in expansion of macro =E2=80=98XPS_M=
IN_MAP_ALLOC=E2=80=99
>>> int alloc_len =3D XPS_MIN_MAP_ALLOC;
>> This is one possibility to fix it:
>>
>> diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
>> index 2d15e38..21cf683 100644
>> --- a/include/linux/netdevice.h
>> +++ b/include/linux/netdevice.h
>> @@ -718,7 +718,7 @@ struct xps_map {
>> u16 queues[0];
>> };
>> #define XPS_MAP_SIZE(_num) (sizeof(struct xps_map) + ((_num) * siz=
eof(u16)))
>> -#define XPS_MIN_MAP_ALLOC ((L1_CACHE_BYTES - sizeof(struct xps_map)=
) \
>> +#define XPS_MIN_MAP_ALLOC ( (L1_CACHE_BYTES > sizeof(struct xps_map=
) ? L1_CACHE_BYTES : 2 * L1_CACHE_BYTES) - sizeof(struct xps_map) \
>> / sizeof(u16))
> But it indicates the whole kernel has the architectural assumption th=
at
> L1_CACHE_BYTES >=3D 32, so I don't think we should be trying to chang=
e
> that.
However, there are already at least two other arches with L1_CACHE_BYTE=
S=20
=3D 16.
Dave
--=20
John David Anglin dave.anglin@bell.net
--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2015-10-22 14:53 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-26 15:38 [PATCH][RFC] parisc: Change L1_CACHE_BYTES to 16 John David Anglin
2015-09-27 16:07 ` [PATCH v2][RFC] " John David Anglin
2015-09-27 16:17 ` James Bottomley
2015-09-27 16:46 ` John David Anglin
2015-10-15 0:32 ` [PATCH v3] " John David Anglin
2015-10-22 11:38 ` Aw: " Helge Deller
2015-10-22 11:53 ` Helge Deller
2015-10-22 14:35 ` James Bottomley
2015-10-22 14:53 ` John David Anglin [this message]
2015-10-22 20:00 ` CONFIG_XPS depends on L1_CACHE_BYTES being greater than sizeof(struct xps_map) Helge Deller
2015-10-22 20:00 ` Helge Deller
2015-10-22 21:37 ` Tom Herbert
2015-10-22 21:37 ` Tom Herbert
2015-10-23 19:21 ` Helge Deller
2015-10-23 19:21 ` Helge Deller
2015-10-23 22:16 ` Tom Herbert
2015-10-23 22:16 ` Tom Herbert
2015-10-22 21:50 ` Eric Dumazet
2015-10-22 21:50 ` Eric Dumazet
2015-10-23 19:25 ` Helge Deller
2015-10-23 19:25 ` Helge Deller
2015-10-23 20:03 ` Eric Dumazet
2015-10-23 21:08 ` Helge Deller
2015-10-23 21:09 ` Helge Deller
2015-10-23 21:38 ` Eric Dumazet
2015-10-23 22:00 ` Alexander Duyck
2015-10-23 22:17 ` Helge Deller
2015-10-23 22:40 ` Alexander Duyck
2015-10-24 14:43 ` Helge Deller
2015-10-25 5:41 ` Alexander Duyck
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=5628F868.3040105@bell.net \
--to=dave.anglin@bell.net \
--cc=James.Bottomley@HansenPartnership.com \
--cc=deller@gmx.de \
--cc=linux-parisc@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.