aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/scsi_devinfo.c
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2007-11-03 14:30:39 -0400
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2008-01-11 19:22:40 -0500
commiteb44820c28bc9a042e1157b41c677018a8fdfc74 (patch)
treede027b3cd40533488805ef7ee8156f077cd2b7e5 /drivers/scsi/scsi_devinfo.c
parent3f48985823001c89c9bd5c5e57cc07530578dfcc (diff)
[SCSI] Add Documentation and integrate into docbook build
Add Documentation/DocBook/scsi_midlayer.tmpl, add to Makefile, and update lots of kerneldoc comments in drivers/scsi/*. Updated with comments from Stefan Richter, Stephen M. Cameron, James Bottomley and Randy Dunlap. Signed-off-by: Rob Landley <rob@landley.net> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/scsi_devinfo.c')
-rw-r--r--drivers/scsi/scsi_devinfo.c34
1 files changed, 15 insertions, 19 deletions
diff --git a/drivers/scsi/scsi_devinfo.c b/drivers/scsi/scsi_devinfo.c
index 348cc5a6e3cd..6839c1004b29 100644
--- a/drivers/scsi/scsi_devinfo.c
+++ b/drivers/scsi/scsi_devinfo.c
@@ -276,11 +276,12 @@ static void scsi_strcpy_devinfo(char *name, char *to, size_t to_length,
276} 276}
277 277
278/** 278/**
279 * scsi_dev_info_list_add: add one dev_info list entry. 279 * scsi_dev_info_list_add - add one dev_info list entry.
280 * @compatible: if true, null terminate short strings. Otherwise space pad.
280 * @vendor: vendor string 281 * @vendor: vendor string
281 * @model: model (product) string 282 * @model: model (product) string
282 * @strflags: integer string 283 * @strflags: integer string
283 * @flag: if strflags NULL, use this flag value 284 * @flags: if strflags NULL, use this flag value
284 * 285 *
285 * Description: 286 * Description:
286 * Create and add one dev_info entry for @vendor, @model, @strflags or 287 * Create and add one dev_info entry for @vendor, @model, @strflags or
@@ -322,8 +323,7 @@ static int scsi_dev_info_list_add(int compatible, char *vendor, char *model,
322} 323}
323 324
324/** 325/**
325 * scsi_dev_info_list_add_str: parse dev_list and add to the 326 * scsi_dev_info_list_add_str - parse dev_list and add to the scsi_dev_info_list.
326 * scsi_dev_info_list.
327 * @dev_list: string of device flags to add 327 * @dev_list: string of device flags to add
328 * 328 *
329 * Description: 329 * Description:
@@ -374,15 +374,15 @@ static int scsi_dev_info_list_add_str(char *dev_list)
374} 374}
375 375
376/** 376/**
377 * get_device_flags - get device specific flags from the dynamic device 377 * get_device_flags - get device specific flags from the dynamic device list.
378 * list. Called during scan time. 378 * @sdev: &scsi_device to get flags for
379 * @vendor: vendor name 379 * @vendor: vendor name
380 * @model: model name 380 * @model: model name
381 * 381 *
382 * Description: 382 * Description:
383 * Search the scsi_dev_info_list for an entry matching @vendor and 383 * Search the scsi_dev_info_list for an entry matching @vendor and
384 * @model, if found, return the matching flags value, else return 384 * @model, if found, return the matching flags value, else return
385 * the host or global default settings. 385 * the host or global default settings. Called during scan time.
386 **/ 386 **/
387int scsi_get_device_flags(struct scsi_device *sdev, 387int scsi_get_device_flags(struct scsi_device *sdev,
388 const unsigned char *vendor, 388 const unsigned char *vendor,
@@ -483,13 +483,11 @@ stop_output:
483} 483}
484 484
485/* 485/*
486 * proc_scsi_dev_info_write: allow additions to the scsi_dev_info_list via 486 * proc_scsi_dev_info_write - allow additions to scsi_dev_info_list via /proc.
487 * /proc.
488 * 487 *
489 * Use: echo "vendor:model:flag" > /proc/scsi/device_info 488 * Description: Adds a black/white list entry for vendor and model with an
490 * 489 * integer value of flag to the scsi device info list.
491 * To add a black/white list entry for vendor and model with an integer 490 * To use, echo "vendor:model:flag" > /proc/scsi/device_info
492 * value of flag to the scsi device info list.
493 */ 491 */
494static int proc_scsi_devinfo_write(struct file *file, const char __user *buf, 492static int proc_scsi_devinfo_write(struct file *file, const char __user *buf,
495 unsigned long length, void *data) 493 unsigned long length, void *data)
@@ -532,8 +530,7 @@ MODULE_PARM_DESC(default_dev_flags,
532 "scsi default device flag integer value"); 530 "scsi default device flag integer value");
533 531
534/** 532/**
535 * scsi_dev_info_list_delete: called from scsi.c:exit_scsi to remove 533 * scsi_dev_info_list_delete - called from scsi.c:exit_scsi to remove the scsi_dev_info_list.
536 * the scsi_dev_info_list.
537 **/ 534 **/
538void scsi_exit_devinfo(void) 535void scsi_exit_devinfo(void)
539{ 536{
@@ -552,13 +549,12 @@ void scsi_exit_devinfo(void)
552} 549}
553 550
554/** 551/**
555 * scsi_dev_list_init: set up the dynamic device list. 552 * scsi_dev_list_init - set up the dynamic device list.
556 * @dev_list: string of device flags to add
557 * 553 *
558 * Description: 554 * Description:
559 * Add command line @dev_list entries, then add 555 * Add command line entries from scsi_dev_flags, then add
560 * scsi_static_device_list entries to the scsi device info list. 556 * scsi_static_device_list entries to the scsi device info list.
561 **/ 557 */
562int __init scsi_init_devinfo(void) 558int __init scsi_init_devinfo(void)
563{ 559{
564#ifdef CONFIG_SCSI_PROC_FS 560#ifdef CONFIG_SCSI_PROC_FS