[PATCH 1/6] staging: vc04_services: Convert dsb() to dsb(sy)

Greg KH gregkh at linuxfoundation.org
Thu Oct 20 01:38:26 PDT 2016


On Wed, Oct 19, 2016 at 03:22:23PM -0700, Michael Zoran wrote:
> On Wed, 2016-10-19 at 13:40 +0200, Greg KH wrote:
> > On Wed, Oct 19, 2016 at 01:34:20AM -0700, Michael Zoran wrote:
> > > > From 52cd77f62e2aabfc70c37533556c95b9d009f1ae Mon Sep 17 00:00:00
> > > > 2001
> > > 
> > > From: Michael Zoran <mzoran at crowfest.net>
> > > Date: Sun, 16 Oct 2016 11:59:40 -0700
> > > Subject: [PATCH 1/6] staging: vc04_services: Convert dsb() to
> > > dsb(sy)
> > > 
> > > The dsb() macro for 32 arm compiles to dsb(sy) in the binary file.
> > > This macro is no longer supported on arm64, so instead use dsb(sy)
> > > which is completely binary compatible.
> > 
> > meta-comment, why use dsb() at all?  Why not use wmb()?  Isn't it the
> > same thing?
> > 
> > thanks,
> > 
> > greg k-h
> 
> No, it's not 100% compatible. 
> 
> arch/arm64/include/asm/barrier.h:#define wmb()		dsb(st)
> 
> When I checked some files into the downstream tree we were able to
> test that dsb() produces exactly the same binary as dsb(sy).
> 
> I'm simply trying to make the smallest change possible that is the
> least likely to raise objections.
> 
> Since the chipset is in the same package as the ARM core, I'm thinking
> it's going to be a very long time before anybody is going to use a non
> ARM32/ARM64 architecture with this driver.

Hm, ok.  I'd really like to be able to enable building the driver if
CONFIG_COMPILE_TEST is enabled, that way you get a lot more build
coverage, and the ability for me to at least test that whitespace and
other cleanup patches don't break the build.

I'll just keep a small "wrapper" patch that I used for testing for stuff
like this, it wasn't the only thing that I had to modify in order to get
it to build for a non-ARM system, so it's not that big of a deal.

thanks,

greg k-h



More information about the linux-rpi-kernel mailing list