WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] PCI passthrough issue

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-devel] PCI passthrough issue
From: Jean Baptiste Favre <xen-devel@xxxxxxxxxxx>
Date: Tue, 01 Feb 2011 17:16:18 +0100
Delivery-date: Tue, 01 Feb 2011 08:16:58 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1296574733.13091.261.camel@xxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <4D2E28C5.30203@xxxxxxxxxxx> <4D2EE1DE.5070006@xxxxxxxxxxx> <4D2F5009.2090701@xxxxxxxxxxx> <20110113201922.GA20494@xxxxxxxxxxxx> <4D2F6431.8030606@xxxxxxxxxxx> <20110114145350.GB7371@xxxxxxxxxxxx> <4D30DC5A.9080303@xxxxxxxxxxx> <4D340504.7020203@xxxxxxxxxxx> <4D344AF4.80301@xxxxxxxxxxx> <4D3AB003.3040603@xxxxxxxxxxx> <20110127202755.GA4194@xxxxxxxxxxxx> <4D41E7EE.4060502@xxxxxxxxxxx> <4D42E520.9020107@xxxxxxxxxxx> <1296560086.13091.131.camel@xxxxxxxxxxxxxxxxxxxxxx> <4D47F9CF.2040107@xxxxxxxxxxx> <1296566401.13091.171.camel@xxxxxxxxxxxxxxxxxxxxxx> <4D4814CE.5050303@xxxxxxxxxxx> <1296569931.13091.194.camel@xxxxxxxxxxxxxxxxxxxxxx> <4D48234F.2020907@xxxxxxxxxxx> <1296574733.13091.261.camel@xxxxxxxxxxxxxxxxxxxxxx>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.9.2.13) Gecko/20101207 Lightning/1.0b2 Thunderbird/3.1.7
Le 01/02/2011 16:38, Ian Campbell a écrit :
> On Tue, 2011-02-01 at 15:14 +0000, Jean Baptiste Favre wrote:
> > Le 01/02/2011 15:18, Ian Campbell a écrit :
>
> >> Assuming the driver is modular:
> >>         "modprobe sky2 copybreak=<N>"
> >>
> >> Depending on your distro there will be somewhere in /etc you can add
> >> this. e.g. on Debian you can create a file in /etc/modprobe.d/
> >> containing "option sky copybreak=<N>" other distros
> >> use /etc/modprobe.conf etc.
> > OK I see but it doesn't seems to have any effect.
> > I tried "option sky copybreak=0" to get all packet copied with no
> change.
>
> The driver is called sky2 not sky so this won't have done anything. I
> typo'd it above, sorry.
My bad, I fixed your typo during tests, but I just copied it while
writing the mail. So basically, using:
# cat /etc/modprobe.d/sky2.conf
option sky2 copybreak=0

does not help.
I have to remove module and load it with right option.
BTW it's not a real issue for me, I can add it in init script :)

> > But I have to say that I'm a bit confused: as I run a PV domU, kernel
> > and initrd are provided by dom0.
> > So basically, I had no module related binaries installed. After
> > installation, I tried to remove module and reload it with different
> > configuration without changes.
> > Is there any way to provide this sort of option in kernel commandline so
> > that it 'll be taken into account even in initrd ?
>
> It depends on your distro and/or initrd tool, I don't know a generic
> answer.
Both are Debian ones.
I've tried to compile kernel from Jeremy's git repo, but face some
problems: it's been a long time since my last kernel compilation and I
did not find all configuration options I need :-/

> If the driver is statically compiled and not modular at all you can do
> <module>.<param>=<value> on the kernel command line, e.g.
> "sky2.copybreak=256".
I may use this way because, as a firewall, I prefer using static kernels :)

> There doesn't appear to be any way to find out what copybreak the driver
> actually uses, short of hacking something into the driver itself. e.g.
>
> diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c
> index 7d85a38..786b8c6 100644
> --- a/drivers/net/sky2.c
> +++ b/drivers/net/sky2.c
> @@ -87,7 +87,7 @@ module_param(debug, int, 0);
>  MODULE_PARM_DESC(debug, "Debug level (0=none,...,16=all)");
>  
>  static int copybreak __read_mostly = 128;
> -module_param(copybreak, int, 0);
> +module_param(copybreak, int, 0444);
>  MODULE_PARM_DESC(copybreak, "Receive copy threshold");
>  
>  static int disable_msi = 0;
>
> Allow you to see the current active value
> in /sys/module/sky2/parameters/copybreak. If you are going to do that
> you might as well just change the constant above though ;-)
Will try this as well

Regards,
JB


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>