Skip to content

proposal: x/sys/unix: Add support for ethtool_cmd and ethtool_value  #62702

@dkumazawa

Description

@dkumazawa

For invoking ioctl with the SIOCETHTOOL request, only EthtoolDrvinfo is supported by x/sys/unix at the moment. This is a proposal to implement support for ethtool_cmd and ethtool_value structs as follows:

  1. Add new structs
type EthtoolCmd struct {
  // struct ethtool_cmd from ethtool.h
}

type EthtoolValue struct {
  // struct ethtool_value from ethtool.h
}
  1. Add new ioctl wrapper functions
func IoctlEthtoolCmd(fd int, ifname string, eCmd *EthtoolCmd) error
func IoctlEthtoolValue(fd int, ifname string, eValue *EthtoolValue) error

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    Incoming

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions