tech-userlevel archive

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

Re: Addition of ppoll(2), a wrapper around pollts(2)



On 25.05.2020 06:06, Martin Husemann wrote:
> On Mon, May 25, 2020 at 04:32:14AM +0530, Apurva Nandan wrote:
>> Hi all,
>> I have added ppoll(2) implementation to libc/sys, which is a wrapper around
>> pollts(2) function (basically, pollts(2) and ppoll(2) are aliases, and
>> NetBSD has pollts(2)).
> 
> Why not just add a weak alias for the function? It seems the only difference
> is the name. Did I overlook something?
> 

Can we rename the syscall name? It would be ideal.

There is no semantical change at all between these two functions.

There is an alias issue, as it works for symbols from a local .c file.
Maybe it could be worke with 'extern' reference to an aliased function?

>> This is done to increase the compatibility
>> with Linux, FreeBSD, OpenBSD, DragonFly and Illumos.
> 
> The man page diff does not suggest any standards that define this function.
> If everyone else just picked a different name, shouldn't we just adjust
> the name and add a weak alias for the old name to keep compatibility
> (and add a note to remove it on the mythical libc bump)?
> 

+ Solaris

This is a non-standard extension, but everybody mainstream (except
macosx that lacks it?) settled on the name ppoll.

>> Please have a look on the patch attached hereby and commit it to base after
>> a review.
> 
> The generated configure changes should probably not be done manually here.
> You did not add any uses of the function internally in libc, so I wonder
> if the namespace.h change is correct.
> 
> If we end up with an alias in the end, no new atf test is needed.
> 

Renaming would be even better.

> Martin
> 


Attachment: signature.asc
Description: OpenPGP digital signature



Home | Main Index | Thread Index | Old Index