aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/cio/cio.c
diff options
context:
space:
mode:
authorCornelia Huck <cornelia.huck@de.ibm.com>2008-10-10 15:33:14 -0400
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2008-10-10 15:33:53 -0400
commit1f4e7edabc4071cdff0133e7e04db2d7287d0e36 (patch)
tree751f447ad52286205502e255d46106e68cb20bf0 /drivers/s390/cio/cio.c
parent9286b7ed682615c1508210f85d26e4c9a5cbf126 (diff)
[S390] bus_id -> dev_set_name() for css and ccw busses
Convert remaining s390 users setting bus_id to dev_set_name() or init_name. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/cio/cio.c')
-rw-r--r--drivers/s390/cio/cio.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/drivers/s390/cio/cio.c b/drivers/s390/cio/cio.c
index 8759912734e0..719d6c406e97 100644
--- a/drivers/s390/cio/cio.c
+++ b/drivers/s390/cio/cio.c
@@ -571,8 +571,10 @@ int cio_validate_subchannel(struct subchannel *sch, struct subchannel_id schid)
571 } 571 }
572 mutex_init(&sch->reg_mutex); 572 mutex_init(&sch->reg_mutex);
573 /* Set a name for the subchannel */ 573 /* Set a name for the subchannel */
574 snprintf (sch->dev.bus_id, BUS_ID_SIZE, "0.%x.%04x", schid.ssid, 574 if (cio_is_console(schid))
575 schid.sch_no); 575 sch->dev.init_name = cio_get_console_sch_name(schid);
576 else
577 dev_set_name(&sch->dev, "0.%x.%04x", schid.ssid, schid.sch_no);
576 578
577 /* 579 /*
578 * The first subchannel that is not-operational (ccode==3) 580 * The first subchannel that is not-operational (ccode==3)
@@ -677,6 +679,7 @@ do_IRQ (struct pt_regs *regs)
677 679
678#ifdef CONFIG_CCW_CONSOLE 680#ifdef CONFIG_CCW_CONSOLE
679static struct subchannel console_subchannel; 681static struct subchannel console_subchannel;
682static char console_sch_name[10] = "0.x.xxxx";
680static struct io_subchannel_private console_priv; 683static struct io_subchannel_private console_priv;
681static int console_subchannel_in_use; 684static int console_subchannel_in_use;
682 685
@@ -827,6 +830,12 @@ cio_get_console_subchannel(void)
827 return &console_subchannel; 830 return &console_subchannel;
828} 831}
829 832
833const char *cio_get_console_sch_name(struct subchannel_id schid)
834{
835 snprintf(console_sch_name, 10, "0.%x.%04x", schid.ssid, schid.sch_no);
836 return (const char *)console_sch_name;
837}
838
830#endif 839#endif
831static int 840static int
832__disable_subchannel_easy(struct subchannel_id schid, struct schib *schib) 841__disable_subchannel_easy(struct subchannel_id schid, struct schib *schib)