1 /* 2 * 3 * Copyright (c) International Business Machines Corp., 2001 4 * 5 * This program is free software; you can redistribute it and/or modify 6 * it under the terms of the GNU General Public License as published by 7 * the Free Software Foundation; either version 2 of the License, or 8 * (at your option) any later version. 9 * 10 * This program is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 * the GNU General Public License for more details. 14 * 15 * You should have received a copy of the GNU General Public License 16 * along with this program; if not, write to the Free Software 17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 18 */ 19 20 21 #define MAG_NUM 'k' 22 #define MODULE_TEST_COMPONENT 0x00023000 23 #define OPTION1 _IO(MAG_NUM, 1) 24 #define _COMPONENT MODULE_TEST_COMPONENT 25 #define TEST_DRIVER_NAME "David's include test module" 26 #define DEVICE_NAME "includeTest" 27 #define DEV_PATH "/dev" 28 #define INCLUDE_DEVICE_PATH DEV_PATH "/" 29 #define INCLUDEMAJOR 253 30 #define MINOR_SHIFT_BITS 3 31 #define MAX_PARTITIONS 8 32 #define MAX_NUM_DISKS 3 33 #define DEV_NAME "includeTest" 34 35 typedef struct _incdev_cmd { 36 u_int32_t cmd; 37 u_int32_t status; 38 } incdev_cmd_t; 39 40 typedef enum incdev_ioctl_cmds_s { 41 INC_IOCTL_NUMBER = 0x5500 42 } incdev_ioctl_cmds_t; 43 44 #define INCDEV_CMD _IOR(INCLUDEMAJOR, INC_IOCTL_NUMBER, incdev_cmd_t**) 45 46 /* 47 * function prototypes 48 */ 49 50 static void option1(void); 51