Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1310520

Re: linux-next: build failure after merge of the akpm tree

From Stephen Rothwell <sfr@canb.auug.org.au>
Newsgroups linux.kernel
Subject Re: linux-next: build failure after merge of the akpm tree
Date 2016-01-16 00:10 +0100
Message-ID <qRlFf-4qa-3@gated-at.bofh.it> (permalink)
References <qLKwF-4mb-7@gated-at.bofh.it> <qQHya-1AL-7@gated-at.bofh.it> <qRjN8-39u-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Andrew,

On Fri, 15 Jan 2016 13:05:27 -0800 Andrew Morton <akpm@linux-foundation.org> wrote:
>
> On Thu, 14 Jan 2016 15:15:41 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> 
> > On Thu, 31 Dec 2015 23:22:10 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:  
> > >
> > > After merging the akpm tree, today's linux-next build (powerpc
> > > allyesconfig) failed like this:
> > > 
> > > sound/core/compress_offload.c: In function 'snd_compr_ioctl':
> > > /home/sfr/next/next/sound/core/compress_offload.c:804:2: error: case label does not reduce to an integer constant
> > >   case _IOC_NR(SNDRV_COMPRESS_GET_CODEC_CAPS):
> > >   ^
> > > 
> > > I have no idea what caused that and have just left it broken for now.  
> > 
> > I am still getting this.  Something in mmotm is causing or exposing this.  
> 
> I'm getting this as well.  If I do
> 
> --- a/include/uapi/sound/compress_offload.h~a
> +++ a/include/uapi/sound/compress_offload.h
> @@ -163,8 +163,7 @@ struct snd_compr_metadata {
>   */
>  #define SNDRV_COMPRESS_IOCTL_VERSION	_IOR('C', 0x00, int)
>  #define SNDRV_COMPRESS_GET_CAPS		_IOWR('C', 0x10, struct snd_compr_caps)
> -#define SNDRV_COMPRESS_GET_CODEC_CAPS	_IOWR('C', 0x11,\
> -						struct snd_compr_codec_caps)
> +#define SNDRV_COMPRESS_GET_CODEC_CAPS	_IOWR('C', 0x11, struct snd_compr_caps)
>  #define SNDRV_COMPRESS_SET_PARAMS	_IOW('C', 0x12, struct snd_compr_params)
>  #define SNDRV_COMPRESS_GET_PARAMS	_IOR('C', 0x13, struct snd_codec)
>  #define SNDRV_COMPRESS_SET_METADATA	_IOW('C', 0x14,\
> 
> then it compiles OK.  So there's something special about `struct
> snd_compr_codec_caps' which is confusing the compiler.

Its very big (hint, I think it is bigger than 1 << 13).

> Looking at the cpp output:
> 
>  case ((((((2U|4U) << (((0 +8)+8)+13)) | ((('C')) << (0 +8)) | (((0x10)) << 0) | (((((sizeof(struct snd_compr_caps) == sizeof(struct snd_compr_caps[1]) && sizeof(struct snd_compr_caps) < (1 << 13)) ? sizeof(struct snd_compr_caps) : __invalid_size_argument_for_IOC))) << ((0 +8)+8)))) >> 0) & ((1 << 8)-1)):
>   retval = snd_compr_get_caps(stream, arg);
>   break;
> 
> ^^ this is SNDRV_COMPRESS_GET_CAPS and it works OK
> 
>  case ((((((2U|4U) << (((0 +8)+8)+13)) | ((('C')) << (0 +8)) | (((0x11)) << 0) | (((((sizeof(struct snd_compr_codec_caps) == sizeof(struct snd_compr_codec_caps[1]) && sizeof(struct snd_compr_codec_caps) < (1 << 13)) ? sizeof(struct snd_compr_codec_caps) : __invalid_size_argument_for_IOC))) << ((0 +8)+8)))) >> 0) & ((1 << 8)-1)):
>   retval = snd_compr_get_codec_caps(stream, arg);
> 
> ^^ this is SNDRV_COMPRESS_GET_CODEC_CAPS and it fails
> 
> And they are identical apart from 0x10 vs 0x11 and the struct name.
> 
> It happens in vanilla linux-next as well, without the -mm patch pile.

Interesting ... what config.  I get this in my powerpc allyesconfig
builds but only after I have added your patches.  So I guess maybe some
kconfig has changed due to your patches that enable this driver to
build.

> Confused.

Me as well :-)

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: linux-next: build failure after merge of the akpm tree Andrew Morton <akpm@linux-foundation.org> - 2016-01-15 22:10 +0100
  Re: linux-next: build failure after merge of the akpm tree Stephen Rothwell <sfr@canb.auug.org.au> - 2016-01-16 00:10 +0100
    Re: linux-next: build failure after merge of the akpm tree Andrew Morton <akpm@linux-foundation.org> - 2016-01-16 00:20 +0100
      Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-16 10:00 +0100
        Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-20 15:20 +0100
          Re: linux-next: build failure after merge of the akpm tree Stephen Rothwell <sfr@canb.auug.org.au> - 2016-01-20 21:40 +0100
            Re: linux-next: build failure after merge of the akpm tree Stephen Rothwell <sfr@canb.auug.org.au> - 2016-01-22 01:30 +0100
              Re: linux-next: build failure after merge of the akpm tree Stephen Rothwell <sfr@canb.auug.org.au> - 2016-01-22 03:50 +0100
                Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-25 10:40 +0100
                Re: linux-next: build failure after merge of the akpm tree Michael Ellerman <mpe@ellerman.id.au> - 2016-01-25 10:50 +0100
                Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-25 11:20 +0100
                Re: linux-next: build failure after merge of the akpm tree Vinod Koul <vinod.koul@intel.com> - 2016-01-25 11:40 +0100
                Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-25 11:50 +0100
                Re: linux-next: build failure after merge of the akpm tree Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2016-01-25 11:50 +0100
                Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-25 12:10 +0100
                Re: linux-next: build failure after merge of the akpm tree Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2016-01-25 12:20 +0100
                Re: linux-next: build failure after merge of the akpm tree Mark Brown <broonie@kernel.org> - 2016-01-25 12:50 +0100
                Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-25 14:20 +0100
                Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-25 14:50 +0100
                Re: linux-next: build failure after merge of the akpm tree Mark Brown <broonie@kernel.org> - 2016-01-25 15:00 +0100
                Re: linux-next: build failure after merge of the akpm tree Vinod Koul <vinod.koul@intel.com> - 2016-01-26 13:50 +0100
                Re: linux-next: build failure after merge of the akpm tree Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2016-01-25 15:10 +0100
                Re: linux-next: build failure after merge of the akpm tree Vinod Koul <vinod.koul@intel.com> - 2016-01-26 13:30 +0100
                Re: linux-next: build failure after merge of the akpm tree Stephen Rothwell <sfr@canb.auug.org.au> - 2016-01-26 22:00 +0100
                Re: linux-next: build failure after merge of the akpm tree Takashi Iwai <tiwai@suse.de> - 2016-01-26 22:30 +0100
              Re: linux-next: build failure after merge of the akpm tree Stephen Rothwell <sfr@canb.auug.org.au> - 2016-01-22 04:10 +0100

csiph-web