tech-x11 archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Building legacy DRM drivers on -current, and the fallout
>> error: case label does not reduce to an integer constant
>> case R128_PM4_64BM_64VCBM_64INDBM:
>> ^~~~
>> error: case label does not reduce to an integer constant
>> case R128_PM4_64PIO_64VCPIO_64INDPIO:
>> ^~~~
> >r128_cce.c: (init->cce_mode != R128_PM4_64BM_64VCBM_64INDBM)) {
> >r128_cce.c: case R128_PM4_64BM_64VCBM_64INDBM:
> >r128_cce.c: case R128_PM4_64PIO_64VCPIO_64INDPIO:
> >r128_drv.h:# define R128_PM4_64BM_64VCBM_64INDBM (8 << 28)
> >r128_drv.h:# define R128_PM4_64PIO_64VCPIO_64INDPIO (15 << 28)
>> -- These look constant to me, and of integer type, [...]
> Perhaps it needs ULL?
Maybe, but I'd expect that to draw a complaint about the size of the
value, not about the type of it. (8 << 28) with 32-bit ints formally
produces undefined behaviour (6.5.7 #4), it's true, but I can't see
anything else wrong with it, and gcc doesn't normally produce errors
that misleading in response to nothing worse than formally undefined
behaviour with a reasonable/expected interpretation.
As for ULL, even making it 8U and 15U would fix that aspect of it; you
don't need ULL.
Personally, I'd take a closer look at r128_drv.h to see if those
#defines are conditional; I'd also build with -E or -save-temps or some
such to look at the preprocessor output - I think the theory that those
symbols aren't expanding to what you expect is worth at least a brief
investigation.
Mouse
Home |
Main Index |
Thread Index |
Old Index