/* Bah... hack to catch console special sausages. */ int cio_is_console(struct subchannel_id schid) { if (!console_subchannel_in_use) return 0; return schid_equal(&schid, &console_subchannel.schid); }
static int check_subchannel(struct device * dev, void * data) { struct subchannel *sch; struct subchannel_id *schid = data; sch = to_subchannel(dev); return schid_equal(&sch->schid, schid); }
static int __clear_io_subchannel_easy(struct subchannel_id schid) { int retry; if (csch(schid)) return -ENODEV; for (retry=0;retry<20;retry++) { struct tpi_info ti; if (tpi(&ti)) { tsch(ti.schid, this_cpu_ptr(&cio_irb)); if (schid_equal(&ti.schid, &schid)) return 0; } udelay_simple(100); } return -EBUSY; }
static inline int __clear_subchannel_easy(struct subchannel_id schid) { int retry; if (csch(schid)) return -ENODEV; for (retry=0;retry<20;retry++) { struct tpi_info ti; if (tpi(&ti)) { tsch(ti.schid, (struct irb *)__LC_IRB); if (schid_equal(&ti.schid, &schid)) return 0; } udelay(100); } return -EBUSY; }