From: Alexey Brodkin <alexey.brodkin@synopsys.com>
To: "peterz@infradead.org" <peterz@infradead.org>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"tglx@linutronix.de" <tglx@linutronix.de>,
"linux-snps-arc@lists.infradead.org"
<linux-snps-arc@lists.infradead.org>,
"stable@vger.kernel.org" <stable@vger.kernel.org>,
"will.deacon@arm.com" <will.deacon@arm.com>,
"greg@kroah.com" <greg@kroah.com>,
"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
"David.Laight@ACULAB.COM" <David.Laight@ACULAB.COM>,
Vineet Gupta <vineet.gupta1@synopsys.com>,
"linux-arch@vger.kernel.org" <linux-arch@vger.kernel.org>,
"geert@linux-m68k.org" <geert@linux-m68k.org>
Subject: Re: [PATCH v3] devres: Explicitly align datai[] to 64-bit
Date: Thu, 4 Oct 2018 16:19:16 +0000 [thread overview]
Message-ID: <ad4f865a92828c3226628a0e378ca2fb4054e96a.camel@synopsys.com> (raw)
In-Reply-To: <4f6e9e8bf60f05872afaed4a1d8e516331e95ea7.camel@synopsys.com>
Hi Peter,
On Mon, 2018-07-09 at 17:53 +0300, Alexey Brodkin wrote:
> Hi Peter,
>
> On Mon, 2018-07-09 at 16:49 +0200, Peter Zijlstra wrote:
> > On Mon, Jul 09, 2018 at 02:33:26PM +0000, Alexey Brodkin wrote:
> > > > In fact, since alloc_dr() uses kmalloc() to allocate the entire thing,
> > > > it is impossible to guarantee a larger alignment than kmalloc does.
> > >
> > > Well but 4-bytes [which is critical for atomic64_t] should be much less
> > > than a sane cache line length so above should work.
> >
> > AFAICT ARCH_KMALLOC_MINALIGN ends up being 4 on x86_32 (it doesn't
> > define ARCH_DMA_MINALIGN and doesn't seem to otherwise override the
> > thing).
> >
> > So unconditionally setting the alignment of devres::data to 8 seems
> > broken.
>
> Well but then what other options do we have to fix a problem with
> misaligned access to atomic64_t in drm_gpu_scheduler?
Ping!
Should I send v4 with ARCH_KMALLOC_MINALIGN used for alignment
if explicitly set __aligned__(8) will break x86_32?
-Alexey
next prev parent reply other threads:[~2018-10-04 16:19 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-09 13:45 Alexey Brodkin
2018-07-09 13:54 ` Peter Zijlstra
2018-07-09 14:04 ` Mark Rutland
2018-07-09 14:10 ` Geert Uytterhoeven
2018-07-09 14:07 ` Alexey Brodkin
2018-07-09 14:07 ` Peter Zijlstra
2018-07-09 14:10 ` Peter Zijlstra
2018-07-09 14:33 ` Alexey Brodkin
2018-07-09 14:49 ` Peter Zijlstra
2018-07-09 14:53 ` Alexey Brodkin
2018-10-04 16:19 ` Alexey Brodkin [this message]
2018-07-09 15:02 ` David Laight
2018-07-09 15:14 ` Peter Zijlstra
2018-07-09 15:29 ` Mark Rutland
2018-07-09 15:34 ` Peter Zijlstra
2018-07-09 15:45 ` Peter Zijlstra
2018-07-09 15:48 ` Mark Rutland
2018-07-09 16:10 ` David Laight
2018-07-09 20:28 ` Vineet Gupta
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=ad4f865a92828c3226628a0e378ca2fb4054e96a.camel@synopsys.com \
--to=alexey.brodkin@synopsys.com \
--cc=David.Laight@ACULAB.COM \
--cc=geert@linux-m68k.org \
--cc=greg@kroah.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-arch@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-snps-arc@lists.infradead.org \
--cc=peterz@infradead.org \
--cc=stable@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=vineet.gupta1@synopsys.com \
--cc=will.deacon@arm.com \
/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
all inboxes | Powered by JetHome®