All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Lunn <andrew@lunn.ch>
To: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	kernel@savoirfairelinux.com,
	"David S. Miller" <davem@davemloft.net>,
	Florian Fainelli <f.fainelli@gmail.com>
Subject: Re: [PATCH v2 net-next v2 10/12] net: dsa: mv88e6xxx: iterate on compatible info
Date: Tue, 14 Jun 2016 23:46:58 +0200	[thread overview]
Message-ID: <20160614214658.GG12832@lunn.ch> (raw)
In-Reply-To: <20160614183153.32327-11-vivien.didelot@savoirfairelinux.com>

On Tue, Jun 14, 2016 at 02:31:51PM -0400, Vivien Didelot wrote:
> With legacy probing, we cannot have a compatible info structure. We have
> to guess it. Instead of using only the first info structure of the info
> table, iterate over the compatible data.
> 
> That way, the legacy code will support new compatible chips with
> different register access without requiring any code change.

I don't think this is safe when used in combination with multi-chip
addresses. This code will perform writes on various addresses,
addresses which could be real registers on a device.

I don't see a need to support guessing. The new binding will work,
without any guessing. So use that.

	Andrew

  parent reply	other threads:[~2016-06-14 21:47 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-14 18:31 [PATCH v2 net-next v2 00/12] net: dsa: mv88e6xxx: misc probe improvements Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 01/12] net: dsa: mv88e6xxx: fix style issues Vivien Didelot
2016-06-14 21:14   ` Andrew Lunn
2016-06-14 18:31 ` [PATCH v2 net-next v2 02/12] net: dsa: mv88e6xxx: remove redundant assignments Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 03/12] net: dsa: mv88e6xxx: use already declared variables Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 04/12] net: dsa: mv88e6xxx: do not increment bus refcount Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 05/12] net: dsa: mv88e6xxx: add switch register helpers Vivien Didelot
2016-06-14 21:17   ` Andrew Lunn
2016-06-14 18:31 ` [PATCH v2 net-next v2 06/12] net: dsa: mv88e6xxx: add port base address to info Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 07/12] net: dsa: mv88e6xxx: put chip info in ID table Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 08/12] net: dsa: mv88e6xxx: read switch ID from info Vivien Didelot
2016-06-14 18:50   ` Sergei Shtylyov
2016-06-14 21:01     ` Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 09/12] net: dsa: mv88e6xxx: add SMI detection helper Vivien Didelot
2016-06-14 21:50   ` Andrew Lunn
2016-06-14 22:10     ` Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 10/12] net: dsa: mv88e6xxx: iterate on compatible info Vivien Didelot
2016-06-14 19:38   ` Sergei Shtylyov
2016-06-14 21:46   ` Andrew Lunn [this message]
2016-06-14 22:13     ` Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 11/12] net: dsa: mv88e6xxx: add an SMI ops structure Vivien Didelot
2016-06-14 22:04   ` Andrew Lunn
2016-06-14 22:26     ` Vivien Didelot
2016-06-14 18:31 ` [PATCH v2 net-next v2 12/12] net: dsa: mv88e6xxx: add addressing mode to info Vivien Didelot
2016-06-14 21:34   ` Andrew Lunn
2016-06-14 21:52     ` Vivien Didelot
2016-06-14 22:09   ` Andrew Lunn
2016-06-14 22:24     ` Vivien Didelot
2016-06-14 22:44       ` Andrew Lunn
2016-06-14 23:11         ` Vivien Didelot

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=20160614214658.GG12832@lunn.ch \
    --to=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=kernel@savoirfairelinux.com \
    --cc=linux-kernel@vger.kernel.org \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.