@@ -104,6 +104,7 @@ enum qeth_ipa_cmds {
104104 IPA_CMD_DELIP = 0xb7 ,
105105 IPA_CMD_SETADAPTERPARMS = 0xb8 ,
106106 IPA_CMD_SET_DIAG_ASS = 0xb9 ,
107+ IPA_CMD_SETBRIDGEPORT = 0xbe ,
107108 IPA_CMD_CREATE_ADDR = 0xc3 ,
108109 IPA_CMD_DESTROY_ADDR = 0xc4 ,
109110 IPA_CMD_REGISTER_LOCAL_ADDR = 0xd1 ,
@@ -500,6 +501,88 @@ struct qeth_ipacmd_diagass {
500501 __u8 cdata [64 ];
501502} __attribute__ ((packed ));
502503
504+ /* SETBRIDGEPORT IPA Command: *********************************************/
505+ enum qeth_ipa_sbp_cmd {
506+ IPA_SBP_QUERY_COMMANDS_SUPPORTED = 0x00000000L ,
507+ IPA_SBP_RESET_BRIDGE_PORT_ROLE = 0x00000001L ,
508+ IPA_SBP_SET_PRIMARY_BRIDGE_PORT = 0x00000002L ,
509+ IPA_SBP_SET_SECONDARY_BRIDGE_PORT = 0x00000004L ,
510+ IPA_SBP_QUERY_BRIDGE_PORTS = 0x00000008L ,
511+ IPA_SBP_BRIDGE_PORT_STATE_CHANGE = 0x00000010L ,
512+ };
513+
514+ struct net_if_token {
515+ __u16 devnum ;
516+ __u8 cssid ;
517+ __u8 iid ;
518+ __u8 ssid ;
519+ __u8 chpid ;
520+ __u16 chid ;
521+ } __packed ;
522+
523+ struct qeth_ipacmd_sbp_hdr {
524+ __u32 supported_sbp_cmds ;
525+ __u32 enabled_sbp_cmds ;
526+ __u16 cmdlength ;
527+ __u16 reserved1 ;
528+ __u32 command_code ;
529+ __u16 return_code ;
530+ __u8 used_total ;
531+ __u8 seq_no ;
532+ __u32 reserved2 ;
533+ } __packed ;
534+
535+ struct qeth_sbp_query_cmds_supp {
536+ __u32 supported_cmds ;
537+ __u32 reserved ;
538+ } __packed ;
539+
540+ struct qeth_sbp_reset_role {
541+ } __packed ;
542+
543+ struct qeth_sbp_set_primary {
544+ struct net_if_token token ;
545+ } __packed ;
546+
547+ struct qeth_sbp_set_secondary {
548+ } __packed ;
549+
550+ struct qeth_sbp_port_entry {
551+ __u8 role ;
552+ __u8 state ;
553+ __u8 reserved1 ;
554+ __u8 reserved2 ;
555+ struct net_if_token token ;
556+ } __packed ;
557+
558+ struct qeth_sbp_query_ports {
559+ __u8 primary_bp_supported ;
560+ __u8 secondary_bp_supported ;
561+ __u8 num_entries ;
562+ __u8 entry_length ;
563+ struct qeth_sbp_port_entry entry [];
564+ } __packed ;
565+
566+ struct qeth_sbp_state_change {
567+ __u8 primary_bp_supported ;
568+ __u8 secondary_bp_supported ;
569+ __u8 num_entries ;
570+ __u8 entry_length ;
571+ struct qeth_sbp_port_entry entry [];
572+ } __packed ;
573+
574+ struct qeth_ipacmd_setbridgeport {
575+ struct qeth_ipacmd_sbp_hdr hdr ;
576+ union {
577+ struct qeth_sbp_query_cmds_supp query_cmds_supp ;
578+ struct qeth_sbp_reset_role reset_role ;
579+ struct qeth_sbp_set_primary set_primary ;
580+ struct qeth_sbp_set_secondary set_secondary ;
581+ struct qeth_sbp_query_ports query_ports ;
582+ struct qeth_sbp_state_change state_change ;
583+ } data ;
584+ } __packed ;
585+
503586/* Header for each IPA command */
504587struct qeth_ipacmd_hdr {
505588 __u8 command ;
@@ -529,6 +612,7 @@ struct qeth_ipa_cmd {
529612 struct qeth_ipacmd_setadpparms setadapterparms ;
530613 struct qeth_set_routing setrtg ;
531614 struct qeth_ipacmd_diagass diagass ;
615+ struct qeth_ipacmd_setbridgeport sbp ;
532616 } data ;
533617} __attribute__ ((packed ));
534618
0 commit comments