diff options
author | Julian Wiedmann <jwi@linux.ibm.com> | 2018-10-12 17:27:13 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-10-12 11:27:00 -0700 |
commit | 4666d7fb1a90280d8d3fa8766b7cdaf822d41a40 (patch) | |
tree | cc2950ebc3e843f4f1e1d4cf88ba90353be3e5dc /drivers/s390/net/qeth_core_mpc.h | |
parent | 1f83b817d0f14ac06ab593b47fdd6f51238cd73e (diff) | |
download | lwn-4666d7fb1a90280d8d3fa8766b7cdaf822d41a40.tar.gz lwn-4666d7fb1a90280d8d3fa8766b7cdaf822d41a40.zip |
s390/qeth: enhance TSO control sequence
TSO6 requires the full programming sequence, and not just a simple
START command. This implements the additional ENABLE command, and adds
some sanity checks that were missing for the START command.
Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/s390/net/qeth_core_mpc.h')
-rw-r--r-- | drivers/s390/net/qeth_core_mpc.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/drivers/s390/net/qeth_core_mpc.h b/drivers/s390/net/qeth_core_mpc.h index aa5de1fe01e1..e85090467afe 100644 --- a/drivers/s390/net/qeth_core_mpc.h +++ b/drivers/s390/net/qeth_core_mpc.h @@ -56,6 +56,21 @@ static inline bool qeth_intparm_is_iob(unsigned long intparm) #define IPA_CMD_INITIATOR_OSA_REPLY 0x81 #define IPA_CMD_PRIM_VERSION_NO 0x01 +struct qeth_ipa_caps { + u32 supported; + u32 enabled; +}; + +static inline bool qeth_ipa_caps_supported(struct qeth_ipa_caps *caps, u32 mask) +{ + return (caps->supported & mask) == mask; +} + +static inline bool qeth_ipa_caps_enabled(struct qeth_ipa_caps *caps, u32 mask) +{ + return (caps->enabled & mask) == mask; +} + enum qeth_card_types { QETH_CARD_TYPE_OSD = 1, QETH_CARD_TYPE_IQD = 5, @@ -405,14 +420,25 @@ struct qeth_checksum_cmd { __u32 enabled; } __packed; +enum qeth_ipa_large_send_caps { + QETH_IPA_LARGE_SEND_TCP = 0x00000001, +}; + +struct qeth_tso_start_data { + u32 mss; + u32 supported; +}; + /* SETASSPARMS IPA Command: */ struct qeth_ipacmd_setassparms { struct qeth_ipacmd_setassparms_hdr hdr; union { __u32 flags_32bit; + struct qeth_ipa_caps caps; struct qeth_checksum_cmd chksum; struct qeth_arp_cache_entry add_arp_entry; struct qeth_arp_query_data query_arp; + struct qeth_tso_start_data tso; __u8 ip[16]; } data; } __attribute__ ((packed)); |