Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[S390] cio: Update documentation.

- read_dev_chars()/read_conf_data() are deprecated. Don't document them, but
advise to issue the channel program from the driver itself.
- Remove some really obsolete and incorrect stuff.

Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>

authored by

Cornelia Huck and committed by
Martin Schwidefsky
85ee32d0 55b637c6

+4 -78
+4 -78
Documentation/s390/cds.txt
··· 51 51 * The interrupt handlers must be adapted to use a ccw_device as argument. 52 52 Moreover, they don't return a devstat, but an irb. 53 53 * Before initiating an io, the options must be set via ccw_device_set_options(). 54 - 55 - read_dev_chars() 56 - read device characteristics 57 - 58 - read_conf_data() 59 - read_conf_data_lpm() 60 - read configuration data. 54 + * Instead of calling read_dev_chars()/read_conf_data(), the driver issues 55 + the channel program and handles the interrupt itself. 61 56 62 57 ccw_device_get_ciw() 63 58 get commands from extended sense data. ··· 125 130 has to call every single device driver registered on this IRQ in order to 126 131 determine the device driver owning the device that raised the interrupt. 127 132 128 - In order not to introduce a new I/O concept to the common Linux code, 129 - Linux/390 preserves the IRQ concept and semantically maps the ESA/390 130 - subchannels to Linux as IRQs. This allows Linux/390 to support up to 64k 131 - different IRQs, uniquely representing a single device each. 132 - 133 133 Up to kernel 2.4, Linux/390 used to provide interfaces via the IRQ (subchannel). 134 134 For internal use of the common I/O layer, these are still there. However, 135 135 device drivers should use the new calling interface via the ccw_device only. ··· 141 151 support using the information saved in the struct ccw_device given to them. 142 152 This methods implies that Linux/390 doesn't require to probe for free (not 143 153 armed) interrupt request lines (IRQs) to drive its devices with. Where 144 - applicable, the device drivers can use the read_dev_chars() to retrieve device 145 - characteristics. This can be done without having to request device ownership 146 - previously. 154 + applicable, the device drivers can use issue the READ DEVICE CHARACTERISTICS 155 + ccw to retrieve device characteristics in its online routine. 147 156 148 157 In order to allow for easy I/O initiation the CDS layer provides a 149 158 ccw_device_start() interface that takes a device specific channel program (one ··· 157 168 ccw_device_halt() function. Some devices require to initially issue a HALT 158 169 SUBCHANNEL (HSCH) command without having pending I/O requests. This function is 159 170 also covered by ccw_device_halt(). 160 - 161 - 162 - read_dev_chars() - Read Device Characteristics 163 - 164 - This routine returns the characteristics for the device specified. 165 - 166 - The function is meant to be called with the device already enabled; that is, 167 - at earliest during set_online() processing. 168 - 169 - The ccw_device must not be locked prior to calling read_dev_chars(). 170 - 171 - The function may be called enabled or disabled. 172 - 173 - int read_dev_chars(struct ccw_device *cdev, void **buffer, int length ); 174 - 175 - cdev - the ccw_device the information is requested for. 176 - buffer - pointer to a buffer pointer. The buffer pointer itself 177 - must contain a valid buffer area. 178 - length - length of the buffer provided. 179 - 180 - The read_dev_chars() function returns : 181 - 182 - 0 - successful completion 183 - -ENODEV - cdev invalid 184 - -EINVAL - an invalid parameter was detected, or the function was called early. 185 - -EBUSY - an irrecoverable I/O error occurred or the device is not 186 - operational. 187 - 188 - 189 - read_conf_data(), read_conf_data_lpm() - Read Configuration Data 190 - 191 - Retrieve the device dependent configuration data. Please have a look at your 192 - device dependent I/O commands for the device specific layout of the node 193 - descriptor elements. read_conf_data_lpm() will retrieve the configuration data 194 - for a specific path. 195 - 196 - The function is meant to be called with the device already enabled; that is, 197 - at earliest during set_online() processing. 198 - 199 - The function may be called enabled or disabled, but the device must not be 200 - locked 201 - 202 - int read_conf_data(struct ccw_device, void **buffer, int *length); 203 - int read_conf_data_lpm(struct ccw_device, void **buffer, int *length, __u8 lpm); 204 - 205 - cdev - the ccw_device the data is requested for. 206 - buffer - Pointer to a buffer pointer. The read_conf_data() routine 207 - will allocate a buffer and initialize the buffer pointer 208 - accordingly. It's the device driver's responsibility to 209 - release the kernel memory if no longer needed. 210 - length - Length of the buffer allocated and retrieved. 211 - lpm - Logical path mask to be used for retrieving the data. If 212 - zero the data is retrieved on the next path available. 213 - 214 - The read_conf_data() function returns : 215 - 0 - Successful completion 216 - -ENODEV - cdev invalid. 217 - -EINVAL - An invalid parameter was detected, or the function was called early. 218 - -EIO - An irrecoverable I/O error occurred or the device is 219 - not operational. 220 - -ENOMEM - The read_conf_data() routine couldn't obtain storage. 221 - -EOPNOTSUPP - The device doesn't support the read configuration 222 - data command. 223 171 224 172 225 173 get_ciw() - get command information word