[PATCH 7/7] sysv: linux: Add 64-bit time_t variant for shmctl

Adhemerval Zanella adhemerval.zanella@linaro.org
Wed Jul 1 12:19:48 GMT 2020



On 30/06/2020 23:28, Alistair Francis wrote:
deps/unix/sysv/linux/powerpc/struct_kernel_shmid64_ds.h b/sysdeps/unix/sysv/linux/powerpc/struct_kernel_shmid64_ds.h
>> new file mode 100644
>> index 0000000000..5533d44dee
>> --- /dev/null
>> +++ b/sysdeps/unix/sysv/linux/powerpc/struct_kernel_shmid64_ds.h
>> @@ -0,0 +1,24 @@
>> +/* Analogous to kernel struct shmid64_ds used on shmctl.  */
>> +struct kernel_shmid64_ds
>> +{
>> +  struct ipc_perm shm_perm;
>> +#if __TIMESIZE == 64
>> +  long int shm_atime;
>> +  long int shm_atime;
>> +  long int shm_atime;
> 
> This fails to compile as all three variables have the same name.

In fact this code specifically is not used on powerpc since it will
either use the __TIMESIZE == 32 (powerpc32) or not use this
structure at all (powerpc64{le}).  But it is still an issue I will
revise the patch for such issues and remove it (maybe adding a
#error if it used on powerpc64).

Besides it, does it work for riscv32 (which should use the default
definition)?


More information about the Libc-alpha mailing list