* [PATCH 1/1] fix mt_fileno and mt_fileno struct mtget members on mips{,n32}
@ 2019-06-07 6:53 Petr Vorel
0 siblings, 0 replies; only message in thread
From: Petr Vorel @ 2019-06-07 6:53 UTC (permalink / raw)
To: musl; +Cc: Petr Vorel
These are defined in kernel sources as daddr_t, which is for mips
(and sparc which we don't support) defined as long.
Other archs define it as int.
Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
---
arch/generic/bits/mtio.h | 9 +++++++++
arch/mips/bits/mtio.h | 9 +++++++++
arch/mipsn32/bits/mtio.h | 9 +++++++++
include/sys/mtio.h | 12 ++----------
4 files changed, 29 insertions(+), 10 deletions(-)
create mode 100644 arch/generic/bits/mtio.h
create mode 100644 arch/mips/bits/mtio.h
create mode 100644 arch/mipsn32/bits/mtio.h
diff --git a/arch/generic/bits/mtio.h b/arch/generic/bits/mtio.h
new file mode 100644
index 00000000..3901eaf2
--- /dev/null
+++ b/arch/generic/bits/mtio.h
@@ -0,0 +1,9 @@
+struct mtget {
+ long mt_type;
+ long mt_resid;
+ long mt_dsreg;
+ long mt_gstat;
+ long mt_erreg;
+ int mt_fileno;
+ int mt_blkno;
+};
diff --git a/arch/mips/bits/mtio.h b/arch/mips/bits/mtio.h
new file mode 100644
index 00000000..ee0073ff
--- /dev/null
+++ b/arch/mips/bits/mtio.h
@@ -0,0 +1,9 @@
+struct mtget {
+ long mt_type;
+ long mt_resid;
+ long mt_dsreg;
+ long mt_gstat;
+ long mt_erreg;
+ long mt_fileno;
+ long mt_blkno;
+};
diff --git a/arch/mipsn32/bits/mtio.h b/arch/mipsn32/bits/mtio.h
new file mode 100644
index 00000000..ee0073ff
--- /dev/null
+++ b/arch/mipsn32/bits/mtio.h
@@ -0,0 +1,9 @@
+struct mtget {
+ long mt_type;
+ long mt_resid;
+ long mt_dsreg;
+ long mt_gstat;
+ long mt_erreg;
+ long mt_fileno;
+ long mt_blkno;
+};
diff --git a/include/sys/mtio.h b/include/sys/mtio.h
index f16a529b..ca995fa9 100644
--- a/include/sys/mtio.h
+++ b/include/sys/mtio.h
@@ -4,6 +4,8 @@
#include <sys/types.h>
#include <sys/ioctl.h>
+#include <bits/mtio.h>
+
struct mtop {
short mt_op;
int mt_count;
@@ -48,16 +50,6 @@ struct mtop {
#define MTSETPART 33
#define MTMKPART 34
-struct mtget {
- long mt_type;
- long mt_resid;
- long mt_dsreg;
- long mt_gstat;
- long mt_erreg;
- int mt_fileno;
- int mt_blkno;
-};
-
#define MT_ISUNKNOWN 0x01
#define MT_ISQIC02 0x02
#define MT_ISWT5150 0x03
--
2.21.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2019-06-07 6:53 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-07 6:53 [PATCH 1/1] fix mt_fileno and mt_fileno struct mtget members on mips{,n32} Petr Vorel
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).