[S390] dasd whitespace and other cosmetics.

Dasd code cleanup: 1) remove white space, 2) remove the emacs override
sections, and 3) use kzalloc instead of kmalloc.

Signed-off-by: Horst Hummel <horst.hummel@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
Horst Hummel 2006-06-29 14:58:12 +02:00 committed by Martin Schwidefsky
parent 63b1224664
commit 138c014dcb
15 changed files with 173 additions and 304 deletions

View file

@ -2172,21 +2172,3 @@ EXPORT_SYMBOL_GPL(dasd_generic_set_online);
EXPORT_SYMBOL_GPL(dasd_generic_set_offline); EXPORT_SYMBOL_GPL(dasd_generic_set_offline);
EXPORT_SYMBOL_GPL(dasd_generic_auto_online); EXPORT_SYMBOL_GPL(dasd_generic_auto_online);
/*
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
* adjust the settings for this buffer only. This must remain at the end
* of the file.
* ---------------------------------------------------------------------------
* Local variables:
* c-indent-level: 4
* c-brace-imaginary-offset: 0
* c-brace-offset: -4
* c-argdecl-indent: 4
* c-label-offset: -4
* c-continued-statement-offset: 4
* c-continued-brace-offset: 0
* indent-tabs-mode: 1
* tab-width: 8
* End:
*/

View file

@ -82,22 +82,3 @@ dasd_3370_erp_examine(struct dasd_ccw_req * cqr, struct irb * irb)
return dasd_era_recover; return dasd_era_recover;
} /* END dasd_3370_erp_examine */ } /* END dasd_3370_erp_examine */
/*
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
* adjust the settings for this buffer only. This must remain at the end
* of the file.
* ---------------------------------------------------------------------------
* Local variables:
* c-indent-level: 4
* c-brace-imaginary-offset: 0
* c-brace-offset: -4
* c-argdecl-indent: 4
* c-label-offset: -4
* c-continued-statement-offset: 4
* c-continued-brace-offset: 0
* indent-tabs-mode: 1
* tab-width: 8
* End:
*/

View file

@ -2723,22 +2723,3 @@ dasd_3990_erp_action(struct dasd_ccw_req * cqr)
return erp; return erp;
} /* end dasd_3990_erp_action */ } /* end dasd_3990_erp_action */
/*
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
* adjust the settings for this buffer only. This must remain at the end
* of the file.
* ---------------------------------------------------------------------------
* Local variables:
* c-indent-level: 4
* c-brace-imaginary-offset: 0
* c-brace-offset: -4
* c-argdecl-indent: 4
* c-label-offset: -4
* c-continued-statement-offset: 4
* c-continued-brace-offset: 0
* indent-tabs-mode: 1
* tab-width: 8
* End:
*/

View file

@ -39,22 +39,3 @@ dasd_9336_erp_examine(struct dasd_ccw_req * cqr, struct irb * irb)
return dasd_era_recover; return dasd_era_recover;
} /* END dasd_9336_erp_examine */ } /* END dasd_9336_erp_examine */
/*
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
* adjust the settings for this buffer only. This must remain at the end
* of the file.
* ---------------------------------------------------------------------------
* Local variables:
* c-indent-level: 4
* c-brace-imaginary-offset: 0
* c-brace-offset: -4
* c-argdecl-indent: 4
* c-label-offset: -4
* c-continued-statement-offset: 4
* c-continued-brace-offset: 0
* indent-tabs-mode: 1
* tab-width: 8
* End:
*/

View file

@ -368,7 +368,7 @@ dasd_add_busid(char *bus_id, int features)
int hash; int hash;
new = (struct dasd_devmap *) new = (struct dasd_devmap *)
kmalloc(sizeof(struct dasd_devmap), GFP_KERNEL); kzalloc(sizeof(struct dasd_devmap), GFP_KERNEL);
if (!new) if (!new)
return ERR_PTR(-ENOMEM); return ERR_PTR(-ENOMEM);
spin_lock(&dasd_devmap_lock); spin_lock(&dasd_devmap_lock);
@ -630,7 +630,8 @@ dasd_ro_show(struct device *dev, struct device_attribute *attr, char *buf)
} }
static ssize_t static ssize_t
dasd_ro_store(struct device *dev, struct device_attribute *attr, const char *buf, size_t count) dasd_ro_store(struct device *dev, struct device_attribute *attr,
const char *buf, size_t count)
{ {
struct dasd_devmap *devmap; struct dasd_devmap *devmap;
int ro_flag; int ro_flag;
@ -673,7 +674,8 @@ dasd_use_diag_show(struct device *dev, struct device_attribute *attr, char *buf)
} }
static ssize_t static ssize_t
dasd_use_diag_store(struct device *dev, struct device_attribute *attr, const char *buf, size_t count) dasd_use_diag_store(struct device *dev, struct device_attribute *attr,
const char *buf, size_t count)
{ {
struct dasd_devmap *devmap; struct dasd_devmap *devmap;
ssize_t rc; ssize_t rc;
@ -697,11 +699,11 @@ dasd_use_diag_store(struct device *dev, struct device_attribute *attr, const cha
return rc; return rc;
} }
static static DEVICE_ATTR(use_diag, 0644, dasd_use_diag_show, dasd_use_diag_store);
DEVICE_ATTR(use_diag, 0644, dasd_use_diag_show, dasd_use_diag_store);
static ssize_t static ssize_t
dasd_discipline_show(struct device *dev, struct device_attribute *attr, char *buf) dasd_discipline_show(struct device *dev, struct device_attribute *attr,
char *buf)
{ {
struct dasd_devmap *devmap; struct dasd_devmap *devmap;
char *dname; char *dname;

View file

@ -336,7 +336,7 @@ dasd_diag_check_device(struct dasd_device *device)
private = (struct dasd_diag_private *) device->private; private = (struct dasd_diag_private *) device->private;
if (private == NULL) { if (private == NULL) {
private = kmalloc(sizeof(struct dasd_diag_private),GFP_KERNEL); private = kzalloc(sizeof(struct dasd_diag_private),GFP_KERNEL);
if (private == NULL) { if (private == NULL) {
DEV_MESSAGE(KERN_WARNING, device, "%s", DEV_MESSAGE(KERN_WARNING, device, "%s",
"memory allocation failed for private data"); "memory allocation failed for private data");

View file

@ -554,7 +554,7 @@ dasd_eckd_check_characteristics(struct dasd_device *device)
private = (struct dasd_eckd_private *) device->private; private = (struct dasd_eckd_private *) device->private;
if (private == NULL) { if (private == NULL) {
private = kmalloc(sizeof(struct dasd_eckd_private), private = kzalloc(sizeof(struct dasd_eckd_private),
GFP_KERNEL | GFP_DMA); GFP_KERNEL | GFP_DMA);
if (private == NULL) { if (private == NULL) {
DEV_MESSAGE(KERN_WARNING, device, "%s", DEV_MESSAGE(KERN_WARNING, device, "%s",
@ -562,7 +562,6 @@ dasd_eckd_check_characteristics(struct dasd_device *device)
"data"); "data");
return -ENOMEM; return -ENOMEM;
} }
memset(private, 0, sizeof(struct dasd_eckd_private));
device->private = (void *) private; device->private = (void *) private;
} }
/* Invalidate status of initial analysis. */ /* Invalidate status of initial analysis. */
@ -1706,22 +1705,3 @@ dasd_eckd_cleanup(void)
module_init(dasd_eckd_init); module_init(dasd_eckd_init);
module_exit(dasd_eckd_cleanup); module_exit(dasd_eckd_cleanup);
/*
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
* adjust the settings for this buffer only. This must remain at the end
* of the file.
* ---------------------------------------------------------------------------
* Local variables:
* c-indent-level: 4
* c-brace-imaginary-offset: 0
* c-brace-offset: -4
* c-argdecl-indent: 4
* c-label-offset: -4
* c-continued-statement-offset: 4
* c-continued-brace-offset: 0
* indent-tabs-mode: 1
* tab-width: 8
* End:
*/

View file

@ -131,7 +131,7 @@ dasd_fba_check_characteristics(struct dasd_device *device)
private = (struct dasd_fba_private *) device->private; private = (struct dasd_fba_private *) device->private;
if (private == NULL) { if (private == NULL) {
private = kmalloc(sizeof(struct dasd_fba_private), GFP_KERNEL); private = kzalloc(sizeof(struct dasd_fba_private), GFP_KERNEL);
if (private == NULL) { if (private == NULL) {
DEV_MESSAGE(KERN_WARNING, device, "%s", DEV_MESSAGE(KERN_WARNING, device, "%s",
"memory allocation failed for private " "memory allocation failed for private "
@ -589,22 +589,3 @@ dasd_fba_cleanup(void)
module_init(dasd_fba_init); module_init(dasd_fba_init);
module_exit(dasd_fba_cleanup); module_exit(dasd_fba_cleanup);
/*
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
* adjust the settings for this buffer only. This must remain at the end
* of the file.
* ---------------------------------------------------------------------------
* Local variables:
* c-indent-level: 4
* c-brace-imaginary-offset: 0
* c-brace-offset: -4
* c-argdecl-indent: 4
* c-label-offset: -4
* c-continued-statement-offset: 4
* c-continued-brace-offset: 0
* indent-tabs-mode: 1
* tab-width: 8
* End:
*/

View file

@ -606,22 +606,3 @@ static inline int dasd_eer_enabled(struct dasd_device *device)
#endif /* __KERNEL__ */ #endif /* __KERNEL__ */
#endif /* DASD_H */ #endif /* DASD_H */
/*
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
* adjust the settings for this buffer only. This must remain at the end
* of the file.
* ---------------------------------------------------------------------------
* Local variables:
* c-indent-level: 4
* c-brace-imaginary-offset: 0
* c-brace-offset: -4
* c-argdecl-indent: 4
* c-label-offset: -4
* c-continued-statement-offset: 4
* c-continued-brace-offset: 0
* indent-tabs-mode: 1
* tab-width: 8
* End:
*/