Lines Matching +full:non +full:- +full:zero

1 /* SPDX-License-Identifier: GPL-2.0 */
17 * struct cmd_scsw - command-mode subchannel status word
24 * @isic: initial-status interruption control
25 * @alcc: address-limit checking control
26 * @ssi: suppress-suspended interruption
27 * @zcc: zero condition code
63 * struct tm_scsw - transport-mode subchannel status word
68 * @x: IRB-format control
69 * @q: interrogate-complete
79 * @schxs: subchannel-extended status
105 * struct eadm_scsw - subchannel status word for eadm subchannels
135 * union scsw - subchannel status word
136 * @cmd: command-mode SCSW
137 * @tm: transport-mode SCSW
219 * scsw_is_tm - check for transport mode scsw
222 * Return non-zero if the specified scsw is a transport mode scsw, zero
227 return css_general_characteristics.fcx && (scsw->tm.x == 1); in scsw_is_tm()
231 * scsw_key - return scsw key field
240 return scsw->tm.key; in scsw_key()
242 return scsw->cmd.key; in scsw_key()
246 * scsw_eswf - return scsw eswf field
255 return scsw->tm.eswf; in scsw_eswf()
257 return scsw->cmd.eswf; in scsw_eswf()
261 * scsw_cc - return scsw cc field
270 return scsw->tm.cc; in scsw_cc()
272 return scsw->cmd.cc; in scsw_cc()
276 * scsw_ectl - return scsw ectl field
285 return scsw->tm.ectl; in scsw_ectl()
287 return scsw->cmd.ectl; in scsw_ectl()
291 * scsw_pno - return scsw pno field
300 return scsw->tm.pno; in scsw_pno()
302 return scsw->cmd.pno; in scsw_pno()
306 * scsw_fctl - return scsw fctl field
315 return scsw->tm.fctl; in scsw_fctl()
317 return scsw->cmd.fctl; in scsw_fctl()
321 * scsw_actl - return scsw actl field
330 return scsw->tm.actl; in scsw_actl()
332 return scsw->cmd.actl; in scsw_actl()
336 * scsw_stctl - return scsw stctl field
345 return scsw->tm.stctl; in scsw_stctl()
347 return scsw->cmd.stctl; in scsw_stctl()
351 * scsw_dstat - return scsw dstat field
360 return scsw->tm.dstat; in scsw_dstat()
362 return scsw->cmd.dstat; in scsw_dstat()
366 * scsw_cstat - return scsw cstat field
375 return scsw->tm.cstat; in scsw_cstat()
377 return scsw->cmd.cstat; in scsw_cstat()
381 * scsw_cmd_is_valid_key - check key field validity
384 * Return non-zero if the key field of the specified command mode scsw is
385 * valid, zero otherwise.
389 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC); in scsw_cmd_is_valid_key()
393 * scsw_cmd_is_valid_sctl - check sctl field validity
396 * Return non-zero if the sctl field of the specified command mode scsw is
397 * valid, zero otherwise.
401 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC); in scsw_cmd_is_valid_sctl()
405 * scsw_cmd_is_valid_eswf - check eswf field validity
408 * Return non-zero if the eswf field of the specified command mode scsw is
409 * valid, zero otherwise.
413 return (scsw->cmd.stctl & SCSW_STCTL_STATUS_PEND); in scsw_cmd_is_valid_eswf()
417 * scsw_cmd_is_valid_cc - check cc field validity
420 * Return non-zero if the cc field of the specified command mode scsw is
421 * valid, zero otherwise.
425 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC) && in scsw_cmd_is_valid_cc()
426 (scsw->cmd.stctl & SCSW_STCTL_STATUS_PEND); in scsw_cmd_is_valid_cc()
430 * scsw_cmd_is_valid_fmt - check fmt field validity
433 * Return non-zero if the fmt field of the specified command mode scsw is
434 * valid, zero otherwise.
438 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC); in scsw_cmd_is_valid_fmt()
442 * scsw_cmd_is_valid_pfch - check pfch field validity
445 * Return non-zero if the pfch field of the specified command mode scsw is
446 * valid, zero otherwise.
450 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC); in scsw_cmd_is_valid_pfch()
454 * scsw_cmd_is_valid_isic - check isic field validity
457 * Return non-zero if the isic field of the specified command mode scsw is
458 * valid, zero otherwise.
462 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC); in scsw_cmd_is_valid_isic()
466 * scsw_cmd_is_valid_alcc - check alcc field validity
469 * Return non-zero if the alcc field of the specified command mode scsw is
470 * valid, zero otherwise.
474 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC); in scsw_cmd_is_valid_alcc()
478 * scsw_cmd_is_valid_ssi - check ssi field validity
481 * Return non-zero if the ssi field of the specified command mode scsw is
482 * valid, zero otherwise.
486 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC); in scsw_cmd_is_valid_ssi()
490 * scsw_cmd_is_valid_zcc - check zcc field validity
493 * Return non-zero if the zcc field of the specified command mode scsw is
494 * valid, zero otherwise.
498 return (scsw->cmd.fctl & SCSW_FCTL_START_FUNC) && in scsw_cmd_is_valid_zcc()
499 (scsw->cmd.stctl & SCSW_STCTL_INTER_STATUS); in scsw_cmd_is_valid_zcc()
503 * scsw_cmd_is_valid_ectl - check ectl field validity
506 * Return non-zero if the ectl field of the specified command mode scsw is
507 * valid, zero otherwise.
511 return (scsw->cmd.stctl & SCSW_STCTL_STATUS_PEND) && in scsw_cmd_is_valid_ectl()
512 !(scsw->cmd.stctl & SCSW_STCTL_INTER_STATUS) && in scsw_cmd_is_valid_ectl()
513 (scsw->cmd.stctl & SCSW_STCTL_ALERT_STATUS); in scsw_cmd_is_valid_ectl()
517 * scsw_cmd_is_valid_pno - check pno field validity
520 * Return non-zero if the pno field of the specified command mode scsw is
521 * valid, zero otherwise.
525 return (scsw->cmd.fctl != 0) && in scsw_cmd_is_valid_pno()
526 (scsw->cmd.stctl & SCSW_STCTL_STATUS_PEND) && in scsw_cmd_is_valid_pno()
527 (!(scsw->cmd.stctl & SCSW_STCTL_INTER_STATUS) || in scsw_cmd_is_valid_pno()
528 ((scsw->cmd.stctl & SCSW_STCTL_INTER_STATUS) && in scsw_cmd_is_valid_pno()
529 (scsw->cmd.actl & SCSW_ACTL_SUSPENDED))); in scsw_cmd_is_valid_pno()
533 * scsw_cmd_is_valid_fctl - check fctl field validity
536 * Return non-zero if the fctl field of the specified command mode scsw is
537 * valid, zero otherwise.
546 * scsw_cmd_is_valid_actl - check actl field validity
549 * Return non-zero if the actl field of the specified command mode scsw is
550 * valid, zero otherwise.
559 * scsw_cmd_is_valid_stctl - check stctl field validity
562 * Return non-zero if the stctl field of the specified command mode scsw is
563 * valid, zero otherwise.
572 * scsw_cmd_is_valid_dstat - check dstat field validity
575 * Return non-zero if the dstat field of the specified command mode scsw is
576 * valid, zero otherwise.
580 return (scsw->cmd.stctl & SCSW_STCTL_STATUS_PEND) && in scsw_cmd_is_valid_dstat()
581 (scsw->cmd.cc != 3); in scsw_cmd_is_valid_dstat()
585 * scsw_cmd_is_valid_cstat - check cstat field validity
588 * Return non-zero if the cstat field of the specified command mode scsw is
589 * valid, zero otherwise.
593 return (scsw->cmd.stctl & SCSW_STCTL_STATUS_PEND) && in scsw_cmd_is_valid_cstat()
594 (scsw->cmd.cc != 3); in scsw_cmd_is_valid_cstat()
598 * scsw_tm_is_valid_key - check key field validity
601 * Return non-zero if the key field of the specified transport mode scsw is
602 * valid, zero otherwise.
606 return (scsw->tm.fctl & SCSW_FCTL_START_FUNC); in scsw_tm_is_valid_key()
610 * scsw_tm_is_valid_eswf - check eswf field validity
613 * Return non-zero if the eswf field of the specified transport mode scsw is
614 * valid, zero otherwise.
618 return (scsw->tm.stctl & SCSW_STCTL_STATUS_PEND); in scsw_tm_is_valid_eswf()
622 * scsw_tm_is_valid_cc - check cc field validity
625 * Return non-zero if the cc field of the specified transport mode scsw is
626 * valid, zero otherwise.
630 return (scsw->tm.fctl & SCSW_FCTL_START_FUNC) && in scsw_tm_is_valid_cc()
631 (scsw->tm.stctl & SCSW_STCTL_STATUS_PEND); in scsw_tm_is_valid_cc()
635 * scsw_tm_is_valid_fmt - check fmt field validity
638 * Return non-zero if the fmt field of the specified transport mode scsw is
639 * valid, zero otherwise.
647 * scsw_tm_is_valid_x - check x field validity
650 * Return non-zero if the x field of the specified transport mode scsw is
651 * valid, zero otherwise.
659 * scsw_tm_is_valid_q - check q field validity
662 * Return non-zero if the q field of the specified transport mode scsw is
663 * valid, zero otherwise.
671 * scsw_tm_is_valid_ectl - check ectl field validity
674 * Return non-zero if the ectl field of the specified transport mode scsw is
675 * valid, zero otherwise.
679 return (scsw->tm.stctl & SCSW_STCTL_STATUS_PEND) && in scsw_tm_is_valid_ectl()
680 !(scsw->tm.stctl & SCSW_STCTL_INTER_STATUS) && in scsw_tm_is_valid_ectl()
681 (scsw->tm.stctl & SCSW_STCTL_ALERT_STATUS); in scsw_tm_is_valid_ectl()
685 * scsw_tm_is_valid_pno - check pno field validity
688 * Return non-zero if the pno field of the specified transport mode scsw is
689 * valid, zero otherwise.
693 return (scsw->tm.fctl != 0) && in scsw_tm_is_valid_pno()
694 (scsw->tm.stctl & SCSW_STCTL_STATUS_PEND) && in scsw_tm_is_valid_pno()
695 (!(scsw->tm.stctl & SCSW_STCTL_INTER_STATUS) || in scsw_tm_is_valid_pno()
696 ((scsw->tm.stctl & SCSW_STCTL_INTER_STATUS) && in scsw_tm_is_valid_pno()
697 (scsw->tm.actl & SCSW_ACTL_SUSPENDED))); in scsw_tm_is_valid_pno()
701 * scsw_tm_is_valid_fctl - check fctl field validity
704 * Return non-zero if the fctl field of the specified transport mode scsw is
705 * valid, zero otherwise.
714 * scsw_tm_is_valid_actl - check actl field validity
717 * Return non-zero if the actl field of the specified transport mode scsw is
718 * valid, zero otherwise.
727 * scsw_tm_is_valid_stctl - check stctl field validity
730 * Return non-zero if the stctl field of the specified transport mode scsw is
731 * valid, zero otherwise.
740 * scsw_tm_is_valid_dstat - check dstat field validity
743 * Return non-zero if the dstat field of the specified transport mode scsw is
744 * valid, zero otherwise.
748 return (scsw->tm.stctl & SCSW_STCTL_STATUS_PEND) && in scsw_tm_is_valid_dstat()
749 (scsw->tm.cc != 3); in scsw_tm_is_valid_dstat()
753 * scsw_tm_is_valid_cstat - check cstat field validity
756 * Return non-zero if the cstat field of the specified transport mode scsw is
757 * valid, zero otherwise.
761 return (scsw->tm.stctl & SCSW_STCTL_STATUS_PEND) && in scsw_tm_is_valid_cstat()
762 (scsw->tm.cc != 3); in scsw_tm_is_valid_cstat()
766 * scsw_tm_is_valid_fcxs - check fcxs field validity
769 * Return non-zero if the fcxs field of the specified transport mode scsw is
770 * valid, zero otherwise.
778 * scsw_tm_is_valid_schxs - check schxs field validity
781 * Return non-zero if the schxs field of the specified transport mode scsw is
782 * valid, zero otherwise.
786 return (scsw->tm.cstat & (SCHN_STAT_PROG_CHECK | in scsw_tm_is_valid_schxs()
793 * scsw_is_valid_actl - check actl field validity
796 * Return non-zero if the actl field of the specified scsw is valid,
798 * Return zero if the field does not contain a valid value.
809 * scsw_is_valid_cc - check cc field validity
812 * Return non-zero if the cc field of the specified scsw is valid,
814 * Return zero if the field does not contain a valid value.
825 * scsw_is_valid_cstat - check cstat field validity
828 * Return non-zero if the cstat field of the specified scsw is valid,
830 * Return zero if the field does not contain a valid value.
841 * scsw_is_valid_dstat - check dstat field validity
844 * Return non-zero if the dstat field of the specified scsw is valid,
846 * Return zero if the field does not contain a valid value.
857 * scsw_is_valid_ectl - check ectl field validity
860 * Return non-zero if the ectl field of the specified scsw is valid,
862 * Return zero if the field does not contain a valid value.
873 * scsw_is_valid_eswf - check eswf field validity
876 * Return non-zero if the eswf field of the specified scsw is valid,
878 * Return zero if the field does not contain a valid value.
889 * scsw_is_valid_fctl - check fctl field validity
892 * Return non-zero if the fctl field of the specified scsw is valid,
894 * Return zero if the field does not contain a valid value.
905 * scsw_is_valid_key - check key field validity
908 * Return non-zero if the key field of the specified scsw is valid,
910 * Return zero if the field does not contain a valid value.
921 * scsw_is_valid_pno - check pno field validity
924 * Return non-zero if the pno field of the specified scsw is valid,
926 * Return zero if the field does not contain a valid value.
937 * scsw_is_valid_stctl - check stctl field validity
940 * Return non-zero if the stctl field of the specified scsw is valid,
942 * Return zero if the field does not contain a valid value.
953 * scsw_cmd_is_solicited - check for solicited scsw
956 * Return non-zero if the command mode scsw indicates that the associated
957 * status condition is solicited, zero if it is unsolicited.
961 return (scsw->cmd.cc != 0) || (scsw->cmd.stctl != in scsw_cmd_is_solicited()
966 * scsw_tm_is_solicited - check for solicited scsw
969 * Return non-zero if the transport mode scsw indicates that the associated
970 * status condition is solicited, zero if it is unsolicited.
974 return (scsw->tm.cc != 0) || (scsw->tm.stctl != in scsw_tm_is_solicited()
979 * scsw_is_solicited - check for solicited scsw
982 * Return non-zero if the transport or command mode scsw indicates that the
983 * associated status condition is solicited, zero if it is unsolicited.