Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) /* SPDX-License-Identifier: GPL-2.0 */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3)  * Author(s)......: Holger Smolinski <Holger.Smolinski@de.ibm.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4)  * Based on.......: linux/drivers/s390/block/mdisk.h
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5)  * ...............: by Hartmunt Penner <hpenner@de.ibm.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6)  * Bugreports.to..: <Linux390@de.ibm.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7)  * Copyright IBM Corp. 1999, 2000
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9)  */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) #define MDSK_WRITE_REQ 0x01
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) #define MDSK_READ_REQ  0x02
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) #define INIT_BIO	0x00
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) #define RW_BIO		0x01
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) #define TERM_BIO	0x02
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) #define DEV_CLASS_FBA	0x01
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) #define DEV_CLASS_ECKD	0x04
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) #define DASD_DIAG_CODE_31BIT		0x03
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) #define DASD_DIAG_CODE_64BIT		0x07
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) #define DASD_DIAG_RWFLAG_ASYNC		0x02
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) #define DASD_DIAG_RWFLAG_NOCACHE	0x01
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) #define DASD_DIAG_FLAGA_FORMAT_64BIT	0x80
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) struct dasd_diag_characteristics {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) 	u16 dev_nr;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) 	u16 rdc_len;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) 	u8 vdev_class;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) 	u8 vdev_type;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) 	u8 vdev_status;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) 	u8 vdev_flags;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) 	u8 rdev_class;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) 	u8 rdev_type;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) 	u8 rdev_model;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) 	u8 rdev_features;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) } __attribute__ ((packed, aligned(4)));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) #define DASD_DIAG_FLAGA_DEFAULT		DASD_DIAG_FLAGA_FORMAT_64BIT
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) typedef u64 blocknum_t;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) typedef s64 sblocknum_t;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) struct dasd_diag_bio {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) 	u8 type;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) 	u8 status;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) 	u8 spare1[2];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51) 	u32 alet;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) 	blocknum_t block_number;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) 	void *buffer;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) } __attribute__ ((packed, aligned(8)));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56) struct dasd_diag_init_io {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57) 	u16 dev_nr;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58) 	u8 flaga;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59) 	u8 spare1[21];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60) 	u32 block_size;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61) 	u8 spare2[4];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62) 	blocknum_t offset;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 63) 	sblocknum_t start_block;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 64) 	blocknum_t end_block;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 65) 	u8  spare3[8];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 66) } __attribute__ ((packed, aligned(8)));
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 67) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 68) struct dasd_diag_rw_io {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 69) 	u16 dev_nr;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 70) 	u8  flaga;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 71) 	u8  spare1[21];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 72) 	u8  key;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 73) 	u8  flags;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 74) 	u8  spare2[2];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 75) 	u32 block_count;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 76) 	u32 alet;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 77) 	u8  spare3[4];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 78) 	u64 interrupt_params;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 79) 	struct dasd_diag_bio *bio_list;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 80) 	u8  spare4[8];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 81) } __attribute__ ((packed, aligned(8)));