bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [util-linux PATCH v2] Support hwclock for GNU Hurd


From: Samuel Thibault
Subject: Re: [util-linux PATCH v2] Support hwclock for GNU Hurd
Date: Mon, 9 Dec 2024 00:54:09 +0100

Zhaoming Luo, le lun. 09 déc. 2024 07:51:38 +0800, a ecrit:
> On 12/9/24 12:43 AM, Samuel Thibault wrote:
> > Hello,
> Hi, thanks for the review.
> > 
> > Zhaoming Luo, le ven. 06 déc. 2024 11:03:26 +0800, a ecrit:
> > > diff --git a/sys-utils/hwclock-cmos.c b/sys-utils/hwclock-cmos.c
> > > index 7e5eecc..cc672cb 100644
> > > --- a/sys-utils/hwclock-cmos.c
> > > +++ b/sys-utils/hwclock-cmos.c
> > > @@ -352,7 +352,9 @@ static int i386_iopl(const int level)
> > >   # else
> > >   static int i386_iopl(const int level __attribute__ ((__unused__)))
> > >   {
> > > + #ifndef __gnu_hurd__
> > >           extern int ioperm(unsigned long from, unsigned long num, int 
> > > turn_on);
> > > + #endif
> > >           return ioperm(clock_ctl_addr, 2, 1);
> > >   }
> > >   # endif
> > 
> > This seems unrelated, do you get an issue without it?
> 
> Got the following errors without it:
> ```
> sys-utils/hwclock-cmos.c: In function 'i386_iopl':
> sys-utils/hwclock-cmos.c:355:20: warning: nested extern declaration of
> 'ioperm' [-Wnested-externs]
>   355 |         extern int ioperm(unsigned long from, unsigned long num, int
> turn_on);
>       |                    ^~~~~~
> sys-utils/hwclock-cmos.c:355:20: warning: redundant redeclaration of
> 'ioperm' [-Wredundant-decls]
> In file included from sys-utils/hwclock-cmos.c:68:
> /usr/include/i386-gnu/sys/io.h:29:12: note: previous declaration of 'ioperm'
> with type 'int(long unsigned int,  long unsigned int,  int)'
>    29 | extern int ioperm (unsigned long int __from, unsigned long int
> __num,
>       |            ^~~~~~
>   CCLD     hwclock
> ```

Ok. Let's see what upstream thinks about it, they'll probably want to
just get rid of the declaration entirely.

Samuel



reply via email to

[Prev in Thread] Current Thread [Next in Thread]