Fix for ioctl numbers for linux/s390 and linux/s390x

Maxim Shchetynin maxim at de.ibm.com
Tue Mar 23 08:51:12 UTC 2004






Hello,

Strace has the wrong ioctl numbers for the dasd module (specific for IBM
eServer zSeries).
The following is a fix for this problem:

(See attached file: strace-4.5.2-dasd-ioctl.diff)

diff -Naur strace-4.5.2/linux/s390/ioctlent.h
strace-4.5.2-dasd-ioctl/linux/s390/ioctlent.h
--- strace-4.5.2/linux/s390/ioctlent.h  2002-10-07 16:37:51.000000000 +0200
+++ strace-4.5.2-dasd-ioctl/linux/s390/ioctlent.h       2004-03-22
14:58:17.000000000 +0100
@@ -103,8 +103,17 @@
 {"linux/agpgart.h", "AGPIOC_ACQUIRE", 0x4101},
 {"linux/agpgart.h", "AGPIOC_RELEASE", 0x4102},
 {"linux/pmu.h", "PMU_IOC_SLEEP", 0x4200},
-{"asm/dasd.h", "BIODASDDISABLE", 0x4401},
-{"asm/dasd.h", "BIODASDENABLE", 0x4402},
+{"asm/dasd.h", "BIODASDDISABLE", 0x4400},
+{"asm/dasd.h", "BIODASDENABLE", 0x4401},
+{"asm/dasd.h", "BIODASDRSRV", 0x4402},
+{"asm/dasd.h", "BIODASDRLSE", 0x4403},
+{"asm/dasd.h", "BIODASDSLCK", 0x4404},
+{"asm/dasd.h", "BIODASDPRRST", 0x4405},
+{"asm/dasd.h", "BIODASDQUIESCE", 0x4406},
+{"asm/dasd.h", "BIODASDRESUME", 0x4407},
+{"asm/cmb.h", "BIODASDCMFENABLE", 0x4420},
+{"asm/cmb.h", "BIODASDCMFDISABLE", 0x4421},
+{"asm/cmb.h", "BIODASDRESETCMB", 0x4422},
 {"linux/fb.h", "FBIOGET_VSCREENINFO", 0x4600},
 {"linux/fb.h", "FBIOPUT_VSCREENINFO", 0x4601},
 {"linux/ps2esdi.h", "CMD_READ", 0x4601},
@@ -312,6 +321,7 @@
 {"asm/ioctls.h", "TIOCSERSETMULTI", 0x545b},
 {"asm/ioctls.h", "TIOCMIWAIT", 0x545c},
 {"asm/ioctls.h", "TIOCGICOUNT", 0x545d},
+{"asm/ioctls.h", "FIOQSIZE", 0x545e},
 {"linux/usbdevice_fs.h", "USBDEVFS_DISCARDURB", 0x550b},
 {"linux/usbdevice_fs.h", "USBDEVFS_RESET", 0x5514},
 {"linux/vt.h", "VT_OPENQRY", 0x5600},
@@ -660,7 +670,7 @@
 {"linux/videodev.h", "VIDIOCSPLAYMODE", 0x400c7618},
 {"linux/video_decoder.h", "DECODER_SET_PICTURE", 0x400e6407},
 {"linux/videodev.h", "VIDIOCSPICT", 0x400e7607},
-{"asm/dasd.h", "BIODASDFORMAT", 0x40104400},
+{"asm/dasd.h", "BIODASDFMT", 0x40104401},
 {"linux/atm_idt77105.h", "IDT77105_GETSTAT", 0x40106132},
 {"linux/atm_idt77105.h", "IDT77105_GETSTATZ", 0x40106133},
 {"linux/atmdev.h", "ATM_GETSTAT", 0x40106150},
@@ -690,11 +700,13 @@
 {"linux/ppdev.h", "PPSETTIME", 0x40107096},
 {"linux/if_ppp.h", "PPPIOCSCOMPRESS", 0x4010744d},
 {"linux/videodev.h", "VIDIOCMCAPTURE", 0x40107613},
+{"asm/tape390.h", "TAPE390_DISPLAY", 0x40116401},
 {"linux/fd.h", "FDSETMAXERRS", 0x4014024c},
 {"linux/videodev.h", "VIDIOCSCAPTURE", 0x40147617},
 {"linux/videodev.h", "VIDIOCSFBUF", 0x4018760c},
 {"linux/fd.h", "FDSETPRM", 0x40200242},
 {"linux/fd.h", "FDDEFPRM", 0x40200243},
+{"asm/dasd.h", "BIODASDSATTR", 0x40204402},
 {"linux/if_ppp.h", "PPPIOCSXASYNCMAP", 0x4020744f},
 {"linux/videodev.h", "VIDIOCSMICROCODE", 0x4020761b},
 {"linux/videodev.h", "VIDIOCSVBIFMT", 0x4020761d},
@@ -710,7 +722,6 @@
 {"linux/videodev.h", "VIDIOCSTUNER", 0x40407605},
 {"linux/fd.h", "FDSETDRVPRM", 0x40800290},
 {"linux/usbdevice_fs.h", "USBDEVFS_GETDRIVER", 0x41045508},
-{"asm/dasd.h", "BIODASDSTVLBL", 0x42004404},
 {"linux/soundcard.h", "SOUND_MIXER_WRITE_VOLUME", 0x60044d00},
 {"linux/soundcard.h", "SOUND_MIXER_WRITE_BASS", 0x60044d01},
 {"linux/soundcard.h", "SOUND_MIXER_WRITE_TREBLE", 0x60044d02},
@@ -744,8 +755,7 @@
 {"linux/capi.h", "CAPI_CLR_FLAGS", 0x80044325},
 {"linux/capi.h", "CAPI_NCCI_OPENCOUNT", 0x80044326},
 {"linux/capi.h", "CAPI_NCCI_GETUNIT", 0x80044327},
-{"asm/dasd.h", "BIODASDRLB", 0x80044407},
-{"asm/dasd.h", "BLKGETBSZ", 0x80044408},
+{"asm/dasd.h", "DASDAPIVER", 0x80044400},
 {"linux/input.h", "EVIOCGVERSION", 0x80044501},
 {"linux/random.h", "RNDGETENTCNT", 0x80045200},
 {"asm/ioctls.h", "TIOCGPTN", 0x80045430},
@@ -845,6 +855,7 @@
 {"linux/ncp_fs.h", "NCP_IOC_SETOBJECTNAME", 0x80186e09},
 {"linux/videodev.h", "VIDIOCGFBUF", 0x8018760b},
 {"linux/fd.h", "FDGETPRM", 0x80200204},
+{"asm/dasd.h", "BIODASDGATTR", 0x80204405},
 {"linux/fb.h", "FBIOGET_VBLANK", 0x80204612},
 {"linux/if_ppp.h", "PPPIOCGXASYNCMAP", 0x80207450},
 {"linux/videodev.h", "VIDIOCGVBIFMT", 0x8020761c},
@@ -855,7 +866,6 @@
 {"linux/rtc.h", "RTC_RD_TIME", 0x80247009},
 {"linux/fd.h", "FDGETFDCSTAT", 0x80280215},
 {"linux/fd.h", "FDWERRORGET", 0x80280217},
-{"asm/dasd.h", "BIODASDRSID", 0x80284406},
 {"linux/rtc.h", "RTC_WKALM_RD", 0x80287010},
 {"linux/videodev.h", "VIDIOCGWIN", 0x80287609},
 {"linux/videodev.h", "VIDIOCGAUDIO", 0x80287610},
@@ -873,14 +883,16 @@
 {"linux/fd.h", "FDGETDRVPRM", 0x80800211},
 {"linux/usbdevice_fs.h", "USBDEVFS_HUB_PORTINFO", 0x80805513},
 {"linux/videodev.h", "VIDIOCGMBUF", 0x80887614},
+{"asm/dasd.h", "BIODASDPSRD", 0x80c04404},
 {"linux/auto_fs.h", "AUTOFS_IOC_EXPIRE", 0x810c9365},
 {"linux/videodev.h", "VIDIOCGPLAYINFO", 0x8118761a},
-{"asm/dasd.h", "BIODASDGTVLBL", 0x82004403},
+{"asm/dasd.h", "BIODASDINFO", 0x81784401},
+{"asm/dasd.h", "BIODASDINFO2", 0x81a04403},
 {"linux/msdos_fs.h", "VFAT_IOCTL_READDIR_BOTH", 0x82307201},
 {"linux/msdos_fs.h", "VFAT_IOCTL_READDIR_SHORT", 0x82307202},
+{"asm/dasd.h", "BIODASDPRRD", 0x84084402},
 {"linux/capi.h", "CAPI_GET_MANUFACTURER", 0xc0044306},
 {"linux/capi.h", "CAPI_GET_SERIAL", 0xc0044308},
-{"asm/dasd.h", "BIODASDRWTB", 0xc0044405},
 {"linux/sonet.h", "SONET_SETDIAG", 0xc0046112},
 {"linux/sonet.h", "SONET_CLRDIAG", 0xc0046113},
 {"linux/synclink.h", "MGSL_IOCWAITEVENT", 0xc0046d08},
@@ -893,6 +905,7 @@
 {"linux/lvm.h", "PV_STATUS", 0xc004fe40},
 {"linux/lvm.h", "PV_CHANGE", 0xc004fe41},
 {"linux/agpgart.h", "AGPIOC_ALLOCATE", 0xc0084106},
+{"asm/cmb.h", "BIODASDREADCMB", 0xc0084420},
 {"linux/coda.h", "CIOC_KERNEL_VERSION", 0xc008630a},
 {"linux/matroxfb.h", "MATROXFB_GET_OUTPUT_MODE", 0xc0086efa},
 {"linux/telephony.h", "PHONE_QUERY_CODEC", 0xc00871a7},
@@ -924,5 +937,5 @@
 {"linux/videodev.h", "VIDIOCGCHAN", 0xc0307602},
 {"linux/capi.h", "CAPI_GET_PROFILE", 0xc0404309},
 {"linux/videodev.h", "VIDIOCGTUNER", 0xc0407604},
+{"asm/cmb.h", "BIODASDREADALLCMB", 0xc0584421},
 {"linux/isdn_ppp.h", "PPPIOCGCALLINFO", 0xc0887480},
-{"asm/dasd.h", "BIODASDEXCP", 0xc0a44409},
diff -Naur strace-4.5.2/linux/s390x/ioctlent.h
strace-4.5.2-dasd-ioctl/linux/s390x/ioctlent.h
--- strace-4.5.2/linux/s390x/ioctlent.h 2002-10-07 16:37:55.000000000 +0200
+++ strace-4.5.2-dasd-ioctl/linux/s390x/ioctlent.h      2004-03-23
16:51:49.000000000 +0100
@@ -103,8 +103,17 @@
 {"linux/agpgart.h", "AGPIOC_ACQUIRE", 0x4101},
 {"linux/agpgart.h", "AGPIOC_RELEASE", 0x4102},
 {"linux/pmu.h", "PMU_IOC_SLEEP", 0x4200},
-{"asm/dasd.h", "BIODASDDISABLE", 0x4401},
-{"asm/dasd.h", "BIODASDENABLE", 0x4402},
+{"asm/dasd.h", "BIODASDDISABLE", 0x4400},
+{"asm/dasd.h", "BIODASDENABLE", 0x4401},
+{"asm/dasd.h", "BIODASDRSRV", 0x4402},
+{"asm/dasd.h", "BIODASDRLSE", 0x4403},
+{"asm/dasd.h", "BIODASDSLCK", 0x4404},
+{"asm/dasd.h", "BIODASDPRRST", 0x4405},
+{"asm/dasd.h", "BIODASDQUIESCE", 0x4406},
+{"asm/dasd.h", "BIODASDRESUME", 0x4407},
+{"asm/cmb.h", "BIODASDCMFENABLE", 0x4420},
+{"asm/cmb.h", "BIODASDCMFDISABLE", 0x4421},
+{"asm/cmb.h", "BIODASDRESETCMB", 0x4422},
 {"linux/fb.h", "FBIOGET_VSCREENINFO", 0x4600},
 {"linux/fb.h", "FBIOPUT_VSCREENINFO", 0x4601},
 {"linux/ps2esdi.h", "CMD_READ", 0x4601},
@@ -312,6 +321,7 @@
 {"asm/ioctls.h", "TIOCSERSETMULTI", 0x545b},
 {"asm/ioctls.h", "TIOCMIWAIT", 0x545c},
 {"asm/ioctls.h", "TIOCGICOUNT", 0x545d},
+{"asm/ioctls.h", "FIOQSIZE", 0x545e},
 {"linux/usbdevice_fs.h", "USBDEVFS_DISCARDURB", 0x550b},
 {"linux/usbdevice_fs.h", "USBDEVFS_RESET", 0x5514},
 {"linux/vt.h", "VT_OPENQRY", 0x5600},
@@ -660,7 +670,7 @@
 {"linux/videodev.h", "VIDIOCSPLAYMODE", 0x400c7618},
 {"linux/video_decoder.h", "DECODER_SET_PICTURE", 0x400e6407},
 {"linux/videodev.h", "VIDIOCSPICT", 0x400e7607},
-{"asm/dasd.h", "BIODASDFORMAT", 0x40104400},
+{"asm/dasd.h", "BIODASDFMT", 0x40104401},
 {"linux/atm_idt77105.h", "IDT77105_GETSTAT", 0x40106132},
 {"linux/atm_idt77105.h", "IDT77105_GETSTATZ", 0x40106133},
 {"linux/atmdev.h", "ATM_GETSTAT", 0x40106150},
@@ -690,11 +700,13 @@
 {"linux/ppdev.h", "PPSETTIME", 0x40107096},
 {"linux/if_ppp.h", "PPPIOCSCOMPRESS", 0x4010744d},
 {"linux/videodev.h", "VIDIOCMCAPTURE", 0x40107613},
+{"asm/tape390.h", "TAPE390_DISPLAY", 0x40116401},
 {"linux/fd.h", "FDSETMAXERRS", 0x4014024c},
 {"linux/videodev.h", "VIDIOCSCAPTURE", 0x40147617},
 {"linux/videodev.h", "VIDIOCSFBUF", 0x4018760c},
 {"linux/fd.h", "FDSETPRM", 0x40200242},
 {"linux/fd.h", "FDDEFPRM", 0x40200243},
+{"asm/dasd.h", "BIODASDSATTR", 0x40204402},
 {"linux/if_ppp.h", "PPPIOCSXASYNCMAP", 0x4020744f},
 {"linux/videodev.h", "VIDIOCSMICROCODE", 0x4020761b},
 {"linux/videodev.h", "VIDIOCSVBIFMT", 0x4020761d},
@@ -710,7 +722,6 @@
 {"linux/videodev.h", "VIDIOCSTUNER", 0x40407605},
 {"linux/fd.h", "FDSETDRVPRM", 0x40800290},
 {"linux/usbdevice_fs.h", "USBDEVFS_GETDRIVER", 0x41045508},
-{"asm/dasd.h", "BIODASDSTVLBL", 0x42004404},
 {"linux/soundcard.h", "SOUND_MIXER_WRITE_VOLUME", 0x60044d00},
 {"linux/soundcard.h", "SOUND_MIXER_WRITE_BASS", 0x60044d01},
 {"linux/soundcard.h", "SOUND_MIXER_WRITE_TREBLE", 0x60044d02},
@@ -744,8 +755,7 @@
 {"linux/capi.h", "CAPI_CLR_FLAGS", 0x80044325},
 {"linux/capi.h", "CAPI_NCCI_OPENCOUNT", 0x80044326},
 {"linux/capi.h", "CAPI_NCCI_GETUNIT", 0x80044327},
-{"asm/dasd.h", "BIODASDRLB", 0x80044407},
-{"asm/dasd.h", "BLKGETBSZ", 0x80044408},
+{"asm/dasd.h", "DASDAPIVER", 0x80044400},
 {"linux/input.h", "EVIOCGVERSION", 0x80044501},
 {"linux/random.h", "RNDGETENTCNT", 0x80045200},
 {"asm/ioctls.h", "TIOCGPTN", 0x80045430},
@@ -845,6 +855,7 @@
 {"linux/ncp_fs.h", "NCP_IOC_SETOBJECTNAME", 0x80186e09},
 {"linux/videodev.h", "VIDIOCGFBUF", 0x8018760b},
 {"linux/fd.h", "FDGETPRM", 0x80200204},
+{"asm/dasd.h", "BIODASDGATTR", 0x80204405},
 {"linux/fb.h", "FBIOGET_VBLANK", 0x80204612},
 {"linux/if_ppp.h", "PPPIOCGXASYNCMAP", 0x80207450},
 {"linux/videodev.h", "VIDIOCGVBIFMT", 0x8020761c},
@@ -855,7 +866,6 @@
 {"linux/rtc.h", "RTC_RD_TIME", 0x80247009},
 {"linux/fd.h", "FDGETFDCSTAT", 0x80280215},
 {"linux/fd.h", "FDWERRORGET", 0x80280217},
-{"asm/dasd.h", "BIODASDRSID", 0x80284406},
 {"linux/rtc.h", "RTC_WKALM_RD", 0x80287010},
 {"linux/videodev.h", "VIDIOCGWIN", 0x80287609},
 {"linux/videodev.h", "VIDIOCGAUDIO", 0x80287610},
@@ -873,14 +883,16 @@
 {"linux/fd.h", "FDGETDRVPRM", 0x80800211},
 {"linux/usbdevice_fs.h", "USBDEVFS_HUB_PORTINFO", 0x80805513},
 {"linux/videodev.h", "VIDIOCGMBUF", 0x80887614},
+{"asm/dasd.h", "BIODASDPSRD", 0x80c04404},
 {"linux/auto_fs.h", "AUTOFS_IOC_EXPIRE", 0x810c9365},
 {"linux/videodev.h", "VIDIOCGPLAYINFO", 0x8118761a},
-{"asm/dasd.h", "BIODASDGTVLBL", 0x82004403},
+{"asm/dasd.h", "BIODASDINFO", 0x81784401},
+{"asm/dasd.h", "BIODASDINFO2", 0x81a04403},
 {"linux/msdos_fs.h", "VFAT_IOCTL_READDIR_BOTH", 0x82307201},
 {"linux/msdos_fs.h", "VFAT_IOCTL_READDIR_SHORT", 0x82307202},
+{"asm/dasd.h", "BIODASDPRRD", 0x84084402},
 {"linux/capi.h", "CAPI_GET_MANUFACTURER", 0xc0044306},
 {"linux/capi.h", "CAPI_GET_SERIAL", 0xc0044308},
-{"asm/dasd.h", "BIODASDRWTB", 0xc0044405},
 {"linux/sonet.h", "SONET_SETDIAG", 0xc0046112},
 {"linux/sonet.h", "SONET_CLRDIAG", 0xc0046113},
 {"linux/synclink.h", "MGSL_IOCWAITEVENT", 0xc0046d08},
@@ -893,6 +905,7 @@
 {"linux/lvm.h", "PV_STATUS", 0xc004fe40},
 {"linux/lvm.h", "PV_CHANGE", 0xc004fe41},
 {"linux/agpgart.h", "AGPIOC_ALLOCATE", 0xc0084106},
+{"asm/cmb.h", "BIODASDREADCMB", 0xc0084420},
 {"linux/coda.h", "CIOC_KERNEL_VERSION", 0xc008630a},
 {"linux/matroxfb.h", "MATROXFB_GET_OUTPUT_MODE", 0xc0086efa},
 {"linux/telephony.h", "PHONE_QUERY_CODEC", 0xc00871a7},
@@ -924,5 +937,5 @@
 {"linux/videodev.h", "VIDIOCGCHAN", 0xc0307602},
 {"linux/capi.h", "CAPI_GET_PROFILE", 0xc0404309},
 {"linux/videodev.h", "VIDIOCGTUNER", 0xc0407604},
+{"asm/cmb.h", "BIODASDREADALLCMB", 0xc0584421},
 {"linux/isdn_ppp.h", "PPPIOCGCALLINFO", 0xc0887480},
-{"asm/dasd.h", "BIODASDEXCP", 0xc0a44409},

Mit freundlichen Grüßen / Best regards

Maxim V. Shchetynin
IBM Deutschland Entwicklung GmbH
Linux für zSeries Entwicklung
Schönaicher Straße 220
71032 Böblingen, Deutschland
-------------- next part --------------
A non-text attachment was scrubbed...
Name: strace-4.5.2-dasd-ioctl.diff
Type: application/octet-stream
Size: 11490 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20040323/b43e5055/attachment.obj>


More information about the Strace-devel mailing list