Skip to contentSkip to conversation

Preferred method for configuration

DISCUSSION Thomas Martitz 4 participants 6 messages Aug 8, 2013 – Aug 13, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Hello,

I'm developing a NIC driver and currently export some custom configuration settings and actions (e.g. enabling a loopback mode) via sysfs. However I read about ioctl() and configfs and am now confused as to what the preferred/expected method is for new drivers.

Best regards.

#1 lore raw
Quoted 5 lines · Thomas Martitz

Hello,

I'm developing a NIC driver and currently export some custom configuration settings and actions (e.g. enabling a loopback mode) via sysfs.

Is there some reason you don't want to use ethtool?

#2 lore raw

Resent with list in CC.

Am 08.08.2013 07:41, schrieb Joe Perches:

Quoted 10 lines · Thomas Martitz
Quoted 5 lines

Hello,

I'm developing a NIC driver and currently export some custom configuration settings and actions (e.g. enabling a loopback mode) via sysfs.

Is there some reason you don't want to use ethtool?

It doesn't allow for custom settings does it? For standards stuff I'm sure going to use ethtool.

Best regards.

#3 lore raw
Quoted 10 lines · Thomas Martitz

Resent with list in CC.

Am 08.08.2013 07:41, schrieb Joe Perches:

Quoted 7 lines · Thomas Martitz
Quoted 5 lines

Hello,

I'm developing a NIC driver and currently export some custom configuration settings and actions (e.g. enabling a loopback mode) via sysfs.

Quoted 6 lines
Quoted 3 lines

Is there some reason you don't want to use ethtool?

It doesn't allow for custom settings does it? For standards stuff I'm sure going to use ethtool.

You can always propose extensions to ethtool.

Note that the ethtool 'features' API already allows setting loopback and there is a 'private flags' API through which you can expose up to 32 arbitrary named flags if they're really not at all generic.

Ben.

Signature · 3 lines
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.
#4 lore raw
In reply to Thomas Martitz
Quoted 10 lines · On Thu, 08 Aug 2013 07:56:04 +0200 Thomas Martitz…

Resent with list in CC.

Am 08.08.2013 07:41, schrieb Joe Perches:

Quoted 7 lines · Thomas Martitz
Quoted 5 lines

Hello,

I'm developing a NIC driver and currently export some custom configuration settings and actions (e.g. enabling a loopback mode) via sysfs.

Quoted 6 lines
Quoted 3 lines

Is there some reason you don't want to use ethtool?

It doesn't allow for custom settings does it? For standards stuff I'm sure going to use ethtool.

Any feature "special to my driver" is sure to meet stiff resistance from the kernel developers. Special features make it impossible for generic configuration in distributions and by management layers.

#5 lore raw

Am 08.08.2013 18:01, schrieb Stephen Hemminger:

Quoted 17 lines
Quoted 14 lines · On Thu, 08 Aug 2013 07:56:04 +0200 Thomas Martitz…

Resent with list in CC.

Am 08.08.2013 07:41, schrieb Joe Perches:

Quoted 10 lines · Thomas Martitz
Quoted 5 lines

Hello,

I'm developing a NIC driver and currently export some custom configuration settings and actions (e.g. enabling a loopback mode) via sysfs.

Is there some reason you don't want to use ethtool?

Quoted 7 lines
Quoted 2 lines

It doesn't allow for custom settings does it? For standards stuff I'm sure going to use ethtool.

Any feature "special to my driver" is sure to meet stiff resistance from the kernel developers. Special features make it impossible for generic configuration in distributions and by management layers.

What about features that are really unique to the device?

Best regards.