From: David Miller <davem@davemloft.net>
To: vivien.didelot@savoirfairelinux.com
Cc: netdev@vger.kernel.org, linux@roeck-us.net, andrew@lunn.ch,
linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com
Subject: Re: [PATCH v2] net: dsa: mv88e6xxx: add write access to debugfs regs file
Date: Fri, 10 Jul 2015 23:01:20 -0700 (PDT) [thread overview]
Message-ID: <20150710.230120.1590955832899872718.davem@davemloft.net> (raw)
In-Reply-To: <1436476409-5033-1-git-send-email-vivien.didelot@savoirfairelinux.com>
From: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Date: Thu, 9 Jul 2015 17:13:29 -0400
> Allow write access to the regs file in the debugfs interface, with the
> following parameters:
>
> echo <name> <reg> <value> > regs
>
> Where "name" is the register name (as shown in the header row), "reg" is
> the register address (as shown in the first column) and "value" is the
> 16-bit value. e.g.:
>
> echo GLOBAL 1a 5550 > regs
>
> Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
I don't know about this.
This starts to smell like a back door for proprietary userspace SDKs to
program the switch hardware.
Yes, they can do it via other mechanisms, but we don't have to make it
any eaiser for them either.
If you want to poke registers, hack the module just like any other
person with appropriate privileges can do.
Frankly, all of this debugfs crap in the DSA drivers smells like poo.
I don't like it _AT_ _ALL_, and I shouldn't have allowed any of it
into the tree in the first place.
I might just remove it all myself, it bothers me so much.
Fetching information should be done by well typed, generic, interfaces
that apply to any similar device or object. All of this debugfs stuff
smells of hacks and special case crap that's only usable for one
device type and that makes it the single most terrible interface to
give to users.
Thanks.
next prev parent reply other threads:[~2015-07-11 6:01 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-09 21:13 [PATCH v2] net: dsa: mv88e6xxx: add write access to debugfs regs file Vivien Didelot
2015-07-11 6:01 ` David Miller [this message]
2015-07-11 18:36 ` Vivien Didelot
2015-07-12 2:08 ` David Miller
2015-07-13 1:39 ` Vivien Didelot
2015-07-13 3:25 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150710.230120.1590955832899872718.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=andrew@lunn.ch \
--cc=kernel@savoirfairelinux.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=netdev@vger.kernel.org \
--cc=vivien.didelot@savoirfairelinux.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).