From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/14192 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: [PATCH 1/2] define daddr_t type Date: Fri, 7 Jun 2019 01:28:51 -0400 Message-ID: <20190607052850.GO1506@brightrain.aerifal.cx> References: <20190607051444.20316-1-petr.vorel@gmail.com> Reply-To: musl@lists.openwall.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="63800"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Mutt/1.5.21 (2010-09-15) To: musl@lists.openwall.com Original-X-From: musl-return-14208-gllmg-musl=m.gmane.org@lists.openwall.com Fri Jun 07 07:29:06 2019 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.89) (envelope-from ) id 1hZ7R4-000GV2-3I for gllmg-musl@m.gmane.org; Fri, 07 Jun 2019 07:29:06 +0200 Original-Received: (qmail 1815 invoked by uid 550); 7 Jun 2019 05:29:04 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 1797 invoked from network); 7 Jun 2019 05:29:03 -0000 Content-Disposition: inline In-Reply-To: <20190607051444.20316-1-petr.vorel@gmail.com> Original-Sender: Rich Felker Xref: news.gmane.org gmane.linux.lib.musl.general:14192 Archived-At: On Fri, Jun 07, 2019 at 07:14:43AM +0200, Petr Vorel wrote: > According to kernel sources only mips (and sparc which we don't support) > defines daddr_t as long, other define int. > > Signed-off-by: Petr Vorel > --- > arch/mips/bits/alltypes.h.in | 2 ++ > arch/mipsn32/bits/alltypes.h.in | 2 ++ > include/alltypes.h.in | 1 + > include/sys/types.h | 1 + > 4 files changed, 6 insertions(+) > > diff --git a/arch/mips/bits/alltypes.h.in b/arch/mips/bits/alltypes.h.in > index 66ca18ad..bd062a85 100644 > --- a/arch/mips/bits/alltypes.h.in > +++ b/arch/mips/bits/alltypes.h.in > @@ -17,6 +17,8 @@ TYPEDEF struct { long long __ll; long double __ld; } max_align_t; > TYPEDEF long time_t; > TYPEDEF long suseconds_t; > > +TYPEDEF long daddr_t; > + > TYPEDEF struct { union { int __i[9]; volatile int __vi[9]; unsigned __s[9]; } __u; } pthread_attr_t; > TYPEDEF struct { union { int __i[6]; volatile int __vi[6]; volatile void *volatile __p[6]; } __u; } pthread_mutex_t; > TYPEDEF struct { union { int __i[6]; volatile int __vi[6]; volatile void *volatile __p[6]; } __u; } mtx_t; > diff --git a/arch/mipsn32/bits/alltypes.h.in b/arch/mipsn32/bits/alltypes.h.in > index 66ca18ad..bd062a85 100644 > --- a/arch/mipsn32/bits/alltypes.h.in > +++ b/arch/mipsn32/bits/alltypes.h.in > @@ -17,6 +17,8 @@ TYPEDEF struct { long long __ll; long double __ld; } max_align_t; > TYPEDEF long time_t; > TYPEDEF long suseconds_t; > > +TYPEDEF long daddr_t; > + > TYPEDEF struct { union { int __i[9]; volatile int __vi[9]; unsigned __s[9]; } __u; } pthread_attr_t; > TYPEDEF struct { union { int __i[6]; volatile int __vi[6]; volatile void *volatile __p[6]; } __u; } pthread_mutex_t; > TYPEDEF struct { union { int __i[6]; volatile int __vi[6]; volatile void *volatile __p[6]; } __u; } mtx_t; > diff --git a/include/alltypes.h.in b/include/alltypes.h.in > index 4cc879b1..6ef6ebd4 100644 > --- a/include/alltypes.h.in > +++ b/include/alltypes.h.in > @@ -18,6 +18,7 @@ TYPEDEF unsigned _Int64 uint64_t; > TYPEDEF unsigned _Int64 u_int64_t; > TYPEDEF unsigned _Int64 uintmax_t; > > +TYPEDEF int daddr_t; > TYPEDEF unsigned mode_t; > TYPEDEF unsigned _Reg nlink_t; > TYPEDEF _Int64 off_t; > diff --git a/include/sys/types.h b/include/sys/types.h > index 75e489c5..c50d21c9 100644 > --- a/include/sys/types.h > +++ b/include/sys/types.h > @@ -29,6 +29,7 @@ extern "C" { > #define __NEED_clock_t > #define __NEED_suseconds_t > #define __NEED_blksize_t > +#define __NEED_daddr_t > > #define __NEED_pthread_t > #define __NEED_pthread_attr_t > -- > 2.21.0 daddr_t is not a standard type, so can't be exposed by default here (aside from the dubious "*_t is always reserved" rule), and it's only proposed to be used in one header, so it doesn't belong in alltypes.h either. Rich