Lines Matching refs:sch
39 struct subchannel *sch;
44 sch = to_subchannel(cdev->dev.parent);
45 private = to_io_private(sch);
47 cc = stsch_err(sch->schid, &schib);
57 dev_name(&sch->dev));
59 "vpm: %02x\n", sch->lpm, sch->opm, sch->vpm);
138 struct subchannel *sch;
141 sch = to_subchannel(cdev->dev.parent);
142 if (cio_update_schib(sch))
144 if (!sch->schib.pmcw.ena)
148 if (!(scsw_actl(&sch->schib.scsw) & SCSW_ACTL_HALT_PEND) &&
149 !(scsw_actl(&sch->schib.scsw) & SCSW_ACTL_CLEAR_PEND)) {
150 if (!scsw_is_tm(&sch->schib.scsw)) {
151 ret = cio_cancel(sch);
159 if (!(scsw_actl(&sch->schib.scsw) & SCSW_ACTL_CLEAR_PEND)) {
163 ret = cio_halt(sch);
173 ret = cio_clear (sch);
205 __recover_lost_chpids(struct subchannel *sch, int old_lpm)
213 if (!(sch->lpm & mask))
217 chpid.id = sch->schib.pmcw.chpid[i];
229 struct subchannel *sch;
232 sch = to_subchannel(cdev->dev.parent);
234 if (cio_disable_subchannel(sch))
240 old_lpm = sch->lpm;
243 if (cio_update_schib(sch))
246 sch->lpm = sch->schib.pmcw.pam & sch->opm;
251 if (sch->lpm != old_lpm)
252 __recover_lost_chpids(sch, old_lpm);
354 struct subchannel *sch = to_subchannel(cdev->dev.parent);
360 cdev->private->path_new_mask = sch->vpm;
374 struct subchannel *sch;
376 sch = to_subchannel(cdev->dev.parent);
381 cio_disable_subchannel(sch);
391 cdev->private->dev_id.devno, sch->schid.sch_no);
399 cdev->private->dev_id.devno, sch->schid.sch_no);
409 sch->schid.sch_no);
433 struct subchannel *sch = to_subchannel(cdev->dev.parent);
445 if (cio_enable_subchannel(sch, (u32) (addr_t) sch)) {
474 struct subchannel *sch = to_subchannel(cdev->dev.parent);
480 if (mask & cdev->private->path_gone_mask & ~(sch->vpm))
482 if (mask & cdev->private->path_new_mask & sch->vpm)
484 if (mask & cdev->private->pgid_reset_mask & sch->vpm)
519 struct subchannel *sch;
521 sch = to_subchannel(cdev->dev.parent);
523 if (cio_update_schib(sch)) {
528 sch->lpm = sch->vpm;
576 struct subchannel *sch;
582 sch = to_subchannel(cdev->dev.parent);
583 ret = cio_enable_subchannel(sch, (u32)(addr_t)sch);
619 struct subchannel *sch;
636 sch = to_subchannel(cdev->dev.parent);
637 if (cio_update_schib(sch))
639 if (scsw_actl(&sch->schib.scsw) != 0)
673 struct subchannel *sch = to_subchannel(cdev->dev.parent);
675 css_schedule_eval(sch->schid);
684 struct subchannel *sch;
690 sch = to_subchannel(cdev->dev.parent);
695 if (cio_update_schib(sch)) {
700 if (scsw_actl(&sch->schib.scsw) != 0 ||
701 (scsw_stctl(&sch->schib.scsw) & SCSW_STCTL_STATUS_PEND) ||
722 struct subchannel *sch = to_subchannel(cdev->dev.parent);
725 if (cio_enable_subchannel(sch, (u32) (addr_t) sch))
730 css_schedule_eval(sch->schid);
911 struct subchannel *sch;
913 sch = to_subchannel(cdev->dev.parent);
914 if (cio_enable_subchannel(sch, (u32)(addr_t)sch) != 0)
923 struct subchannel *sch;
928 sch = to_subchannel(cdev->dev.parent);
930 if (cio_update_schib(sch))
936 sch->lpm = sch->schib.pmcw.pam & sch->opm;
941 io_subchannel_init_config(sch);
942 if (cio_commit_config(sch))
946 /* Check if this is another device which appeared on the same sch. */
947 if (sch->schib.pmcw.dev != cdev->private->dev_id.devno)
948 css_schedule_eval(sch->schid);
956 struct subchannel *sch;
958 sch = to_subchannel(cdev->dev.parent);
963 cio_disable_subchannel(sch);