[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <a75bc7c92bd9806a56ec2736218dec15b5cf7eba.camel@gmail.com>
Date: Tue, 25 Sep 2018 23:12:53 +0300
From: Yasha Cherikovsky <yasha.che3@...il.com>
To: Paul Burton <paul.burton@...s.com>
Cc: Ralf Baechle <ralf@...ux-mips.org>,
James Hogan <jhogan@...nel.org>,
"linux-mips@...ux-mips.org" <linux-mips@...ux-mips.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 1/1] MIPS: Add new Kconfig variable to avoid unaligned
access instructions
On Tue, 2018-09-25 at 19:57 +0000, Paul Burton wrote:
> Hi Yasha,
>
> On Tue, Sep 25, 2018 at 10:30:52PM +0300, Yasha Cherikovsky wrote:
> > On Tue, 2018-09-25 at 17:45 +0000, Paul Burton wrote:
> > > How about we:
> > >
> > > - Add a Kconfig option CONFIG_CPU_SUPPORTS_LOAD_STORE_LR, and
> > > select
> > > it for all existing pre-r6 targets (probably from CONFIG_CPU_*).
> > >
> > > - Change CONFIG_GENERIC_CSUM to default y if
> > > !CONFIG_CPU_SUPPORTS_LOAD_STORE_LR, and drop the selects of it.
> > >
> > > That would avoid the double-negative ("if we don't not support this")
> > > that the #ifndef's currently represent. It would also mean any future
> > > architecture/ISA targets beyond MIPSr6 automatically avoid the
> > > instructions.
> >
> > Thanks for your feedback, I'll start preparing v2.
> >
> > Looking in arch/mips/Kconfig, some CPU options start
> > with CPU_SUPPORTS_ and some with CPU_HAS_.
> > Which perfix should we use here?
>
> That's a good question :)
>
> To be honest I don't think either of them is perfect, since what we're
> really describing is what's supported by the ISA that the kernel build
> is targeting - and in theory the CPU we actually run on could support
> extra things.
>
> But considering it I think CPU_HAS_ is probably the best choice for
> this, since it's already used similarly to indicate support for pref &
> sync instructions.
>
> Thanks,
> Paul
OK, Thanks.
Powered by blists - more mailing lists