diff mbox

[net] net: ethernet: davicom: Allow to select DM9000 for nios2

Message ID 1418376071-28709-1-git-send-email-tklauser@distanz.ch
State Accepted, archived
Delegated to: David Miller
Headers show

Commit Message

Tobias Klauser Dec. 12, 2014, 9:21 a.m. UTC
This chip is present on older revisions of the DE2 development kit.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
---
 drivers/net/ethernet/davicom/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

David Laight Dec. 12, 2014, 9:49 a.m. UTC | #1
From: Tobias Klauser
> This chip is present on older revisions of the DE2 development kit.

Doesn't that mean the selector should be DE2 not NIOS2.

NIOS2 is a cpu not a board and I think this is an external peripheral
not something implemented in the fpga itself.

	David

> 
> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
> ---
>  drivers/net/ethernet/davicom/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/davicom/Kconfig b/drivers/net/ethernet/davicom/Kconfig
> index 316c5e5..7ec2d74 100644
> --- a/drivers/net/ethernet/davicom/Kconfig
> +++ b/drivers/net/ethernet/davicom/Kconfig
> @@ -4,7 +4,7 @@
> 
>  config DM9000
>  	tristate "DM9000 support"
> -	depends on ARM || BLACKFIN || MIPS || COLDFIRE
> +	depends on ARM || BLACKFIN || MIPS || COLDFIRE || NIOS2
>  	select CRC32
>  	select MII
>  	---help---
> --
> 2.2.0
> 
> 
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Tobias Klauser Dec. 12, 2014, 9:57 a.m. UTC | #2
On 2014-12-12 at 10:49:13 +0100, David Laight <David.Laight@ACULAB.COM> wrote:
> From: Tobias Klauser
> > This chip is present on older revisions of the DE2 development kit.
> 
> Doesn't that mean the selector should be DE2 not NIOS2.
> 
> NIOS2 is a cpu not a board and I think this is an external peripheral
> not something implemented in the fpga itself.

You're of course right, but since nios2 relies on device tree there is
no notion of a specific board at compile time.

Moreover, the chip might be used on other boards (I personally know of
at least one) based on the nios2 softcore.

Cheers
Tobias
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
David Laight Dec. 12, 2014, 10:08 a.m. UTC | #3
From: Tobias Klauser
> On 2014-12-12 at 10:49:13 +0100, David Laight <David.Laight@ACULAB.COM> wrote:
> > From: Tobias Klauser
> > > This chip is present on older revisions of the DE2 development kit.
> >
> > Doesn't that mean the selector should be DE2 not NIOS2.
> >
> > NIOS2 is a cpu not a board and I think this is an external peripheral
> > not something implemented in the fpga itself.
> 
> You're of course right, but since nios2 relies on device tree there is
> no notion of a specific board at compile time.
> 
> Moreover, the chip might be used on other boards (I personally know of
> at least one) based on the nios2 softcore.

And I've got several boards on my desk that have Altera fpgas and
could conceivably run linux, none of which have that chip.

Given the typical memory size constraints of such systems I can't
actually imagine anyone wanting to run anything other than a
specific cut-down kernel with a similarly cut-down userspace.

With actual hardware you might want any PCIe device (since the
fpga can be a PCIe host).
So whereas you might want almost any device, you probably want
almost none of them.

So trying to build a 'one size fits all' kernel is completely doomed.

	David



--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Tobias Klauser Dec. 12, 2014, 10:17 a.m. UTC | #4
On 2014-12-12 at 11:08:03 +0100, David Laight <David.Laight@ACULAB.COM> wrote:
> From: Tobias Klauser
> > On 2014-12-12 at 10:49:13 +0100, David Laight <David.Laight@ACULAB.COM> wrote:
> > > From: Tobias Klauser
> > > > This chip is present on older revisions of the DE2 development kit.
> > >
> > > Doesn't that mean the selector should be DE2 not NIOS2.
> > >
> > > NIOS2 is a cpu not a board and I think this is an external peripheral
> > > not something implemented in the fpga itself.
> > 
> > You're of course right, but since nios2 relies on device tree there is
> > no notion of a specific board at compile time.
> > 
> > Moreover, the chip might be used on other boards (I personally know of
> > at least one) based on the nios2 softcore.
> 
> And I've got several boards on my desk that have Altera fpgas and
> could conceivably run linux, none of which have that chip.
> 
> Given the typical memory size constraints of such systems I can't
> actually imagine anyone wanting to run anything other than a
> specific cut-down kernel with a similarly cut-down userspace.
> 
> With actual hardware you might want any PCIe device (since the
> fpga can be a PCIe host).
> So whereas you might want almost any device, you probably want
> almost none of them.
> 
> So trying to build a 'one size fits all' kernel is completely doomed.

I completely agree. However I don't see how this has anything to do with
this patch, as it only allows to select the driver but doesn't do so by
default.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Simon Horman Dec. 12, 2014, 11:28 a.m. UTC | #5
On Fri, Dec 12, 2014 at 10:21:11AM +0100, Tobias Klauser wrote:
> This chip is present on older revisions of the DE2 development kit.
> 
> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>

I wonder if || COMPILE_TEST should also be added to allow extra build
coverage. Is there a specific reason it won't compile more widely?

Likewise for your smsc patch.

> ---
>  drivers/net/ethernet/davicom/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/davicom/Kconfig b/drivers/net/ethernet/davicom/Kconfig
> index 316c5e5..7ec2d74 100644
> --- a/drivers/net/ethernet/davicom/Kconfig
> +++ b/drivers/net/ethernet/davicom/Kconfig
> @@ -4,7 +4,7 @@
>  
>  config DM9000
>  	tristate "DM9000 support"
> -	depends on ARM || BLACKFIN || MIPS || COLDFIRE
> +	depends on ARM || BLACKFIN || MIPS || COLDFIRE || NIOS2
>  	select CRC32
>  	select MII
>  	---help---
> -- 
> 2.2.0
> 
> 
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Tobias Klauser Dec. 12, 2014, 12:40 p.m. UTC | #6
On 2014-12-12 at 12:28:42 +0100, Simon Horman <horms@verge.net.au> wrote:
> On Fri, Dec 12, 2014 at 10:21:11AM +0100, Tobias Klauser wrote:
> > This chip is present on older revisions of the DE2 development kit.
> > 
> > Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
> 
> I wonder if || COMPILE_TEST should also be added to allow extra build
> coverage. Is there a specific reason it won't compile more widely?
> 
> Likewise for your smsc patch.

Good point. I don't think there's a reason for it not being compiled
more widely. Should I update my patches accordingly or send a separate
patch?
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Simon Horman Dec. 12, 2014, 1:58 p.m. UTC | #7
On Fri, Dec 12, 2014 at 01:40:15PM +0100, Tobias Klauser wrote:
> On 2014-12-12 at 12:28:42 +0100, Simon Horman <horms@verge.net.au> wrote:
> > On Fri, Dec 12, 2014 at 10:21:11AM +0100, Tobias Klauser wrote:
> > > This chip is present on older revisions of the DE2 development kit.
> > > 
> > > Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
> > 
> > I wonder if || COMPILE_TEST should also be added to allow extra build
> > coverage. Is there a specific reason it won't compile more widely?
> > 
> > Likewise for your smsc patch.
> 
> Good point. I don't think there's a reason for it not being compiled
> more widely. Should I update my patches accordingly or send a separate
> patch?

I'm not the maintainer but a follow-up patch or patches seems reasonable to me.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
David Miller Dec. 12, 2014, 4:26 p.m. UTC | #8
From: Tobias Klauser <tklauser@distanz.ch>
Date: Fri, 12 Dec 2014 10:21:11 +0100

> This chip is present on older revisions of the DE2 development kit.
> 
> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>

Applied.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/net/ethernet/davicom/Kconfig b/drivers/net/ethernet/davicom/Kconfig
index 316c5e5..7ec2d74 100644
--- a/drivers/net/ethernet/davicom/Kconfig
+++ b/drivers/net/ethernet/davicom/Kconfig
@@ -4,7 +4,7 @@ 
 
 config DM9000
 	tristate "DM9000 support"
-	depends on ARM || BLACKFIN || MIPS || COLDFIRE
+	depends on ARM || BLACKFIN || MIPS || COLDFIRE || NIOS2
 	select CRC32
 	select MII
 	---help---