Message ID | 20210426074812.27798-1-sujiaxun@uniontech.com |
---|---|
State | Accepted |
Headers | show |
Series | Fix the 64-bit macro definition of mips architecture | expand |
Hi Viresh, Please process the patch below. > The mips architecture gcc does not have a built-in __arch64__, > you can also use "__BITS_PER_LONG == 64" > > Signed-off-by: sujiaxun <sujiaxun@uniontech.com> > --- > include/lapi/msgbuf.h | 2 +- > include/lapi/sembuf.h | 2 +- > include/lapi/shmbuf.h | 2 +- > 3 files changed, 3 insertions(+), 3 deletions(-) > > diff --git a/include/lapi/msgbuf.h b/include/lapi/msgbuf.h > index f3277270d..873902e95 100644 > --- a/include/lapi/msgbuf.h > +++ b/include/lapi/msgbuf.h > @@ -17,7 +17,7 @@ > #if defined(__mips__) > #define HAVE_MSQID64_DS > > -#if defined(__arch64__) > +#if __BITS_PER_LONG == 64 > /* > * The msqid64_ds structure for the MIPS architecture. > * Note extra padding because this structure is passed back and forth > diff --git a/include/lapi/sembuf.h b/include/lapi/sembuf.h > index 4ef0483a0..66579d294 100644 > --- a/include/lapi/sembuf.h > +++ b/include/lapi/sembuf.h > @@ -24,7 +24,7 @@ > * Pad space is left for 2 miscellaneous 64-bit values on mips64, > * but used for the upper 32 bit of the time values on mips32. > */ > -#if defined(__arch64__) > +#if __BITS_PER_LONG == 64 > struct semid64_ds { > struct ipc64_perm sem_perm; /* permissions .. see ipc.h */ > long sem_otime; /* last semop time */ > diff --git a/include/lapi/shmbuf.h b/include/lapi/shmbuf.h > index 28ee33620..ad71d9431 100644 > --- a/include/lapi/shmbuf.h > +++ b/include/lapi/shmbuf.h > @@ -27,7 +27,7 @@ > * data structure when moving to 64-bit time_t. > */ > > -#if defined(__arch64__) > +#if __BITS_PER_LONG == 64 > struct shmid64_ds { > struct ipc64_perm shm_perm; /* operation perms */ > size_t shm_segsz; /* size of segment (bytes) */ > -- > 2.20.1 > > >
On 26-04-21, 17:00, sujiaxun wrote: > Hi Viresh, > > Please process the patch below. > > > > The mips architecture gcc does not have a built-in __arch64__, > > you can also use "__BITS_PER_LONG == 64" > > > > Signed-off-by: sujiaxun <sujiaxun@uniontech.com> > > --- > > include/lapi/msgbuf.h | 2 +- > > include/lapi/sembuf.h | 2 +- > > include/lapi/shmbuf.h | 2 +- > > 3 files changed, 3 insertions(+), 3 deletions(-) > > > > diff --git a/include/lapi/msgbuf.h b/include/lapi/msgbuf.h > > index f3277270d..873902e95 100644 > > --- a/include/lapi/msgbuf.h > > +++ b/include/lapi/msgbuf.h > > @@ -17,7 +17,7 @@ > > #if defined(__mips__) > > #define HAVE_MSQID64_DS > > > > -#if defined(__arch64__) > > +#if __BITS_PER_LONG == 64 > > /* > > * The msqid64_ds structure for the MIPS architecture. > > * Note extra padding because this structure is passed back and forth > > diff --git a/include/lapi/sembuf.h b/include/lapi/sembuf.h > > index 4ef0483a0..66579d294 100644 > > --- a/include/lapi/sembuf.h > > +++ b/include/lapi/sembuf.h > > @@ -24,7 +24,7 @@ > > * Pad space is left for 2 miscellaneous 64-bit values on mips64, > > * but used for the upper 32 bit of the time values on mips32. > > */ > > -#if defined(__arch64__) > > +#if __BITS_PER_LONG == 64 > > struct semid64_ds { > > struct ipc64_perm sem_perm; /* permissions .. see ipc.h */ > > long sem_otime; /* last semop time */ > > diff --git a/include/lapi/shmbuf.h b/include/lapi/shmbuf.h > > index 28ee33620..ad71d9431 100644 > > --- a/include/lapi/shmbuf.h > > +++ b/include/lapi/shmbuf.h > > @@ -27,7 +27,7 @@ > > * data structure when moving to 64-bit time_t. > > */ > > > > -#if defined(__arch64__) > > +#if __BITS_PER_LONG == 64 > > struct shmid64_ds { > > struct ipc64_perm shm_perm; /* operation perms */ > > size_t shm_segsz; /* size of segment (bytes) */ Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Hi, > The mips architecture gcc does not have a built-in __arch64__, > you can also use "__BITS_PER_LONG == 64" Thanks for the fix, merged! Please next time mark new version of the patchset with -vN switch (e.g. in this case: git format-patch origin/master -v2). Kind regards, Petr
diff --git a/include/lapi/msgbuf.h b/include/lapi/msgbuf.h index f3277270d..873902e95 100644 --- a/include/lapi/msgbuf.h +++ b/include/lapi/msgbuf.h @@ -17,7 +17,7 @@ #if defined(__mips__) #define HAVE_MSQID64_DS -#if defined(__arch64__) +#if __BITS_PER_LONG == 64 /* * The msqid64_ds structure for the MIPS architecture. * Note extra padding because this structure is passed back and forth diff --git a/include/lapi/sembuf.h b/include/lapi/sembuf.h index 4ef0483a0..66579d294 100644 --- a/include/lapi/sembuf.h +++ b/include/lapi/sembuf.h @@ -24,7 +24,7 @@ * Pad space is left for 2 miscellaneous 64-bit values on mips64, * but used for the upper 32 bit of the time values on mips32. */ -#if defined(__arch64__) +#if __BITS_PER_LONG == 64 struct semid64_ds { struct ipc64_perm sem_perm; /* permissions .. see ipc.h */ long sem_otime; /* last semop time */ diff --git a/include/lapi/shmbuf.h b/include/lapi/shmbuf.h index 28ee33620..ad71d9431 100644 --- a/include/lapi/shmbuf.h +++ b/include/lapi/shmbuf.h @@ -27,7 +27,7 @@ * data structure when moving to 64-bit time_t. */ -#if defined(__arch64__) +#if __BITS_PER_LONG == 64 struct shmid64_ds { struct ipc64_perm shm_perm; /* operation perms */ size_t shm_segsz; /* size of segment (bytes) */
The mips architecture gcc does not have a built-in __arch64__, you can also use "__BITS_PER_LONG == 64" Signed-off-by: sujiaxun <sujiaxun@uniontech.com> --- include/lapi/msgbuf.h | 2 +- include/lapi/sembuf.h | 2 +- include/lapi/shmbuf.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) -- 2.20.1