Re: network interfaces called "all", "default" or "config"

2014-08-15 Thread Stephane Chazelas
link eth0 foo:bar type vlan id 123 should not be allowed. Worse: ip link add link eth0 foo:bar type vlan id 1 ip link add link eth0 foo type vlan id 2 ip link del foo:bar deletes foo instead of foo:bar. On 14 August 2014 19:37, Cong Wang wrote: > On Thu, Aug 14, 2014 at 2:41 AM, Step

Re: network interfaces called all, default or config

2014-08-15 Thread Stephane Chazelas
, Stephane Chazelas stephane.chaze...@gmail.com wrote: By the way, this is related: $ ip link add link eth0 eth0:123 type vlan id 123 $ ip link del link eth0 eth0:123 RTNETLINK answers: Operation not supported Kernel reads eth0:123 as an alias of eth0, so it will just truncate the dev name

Re: network interfaces called "all", "default" or "config"

2014-08-14 Thread Stephane Chazelas
"RTNETLINK answers: Operation not supported\n", 43) = 43 exit_group(2) = ? vconfig rem: socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 3 ioctl(3, SIOCSIFVLAN, 0x7fff67a00110) = 0 Cheers, Stephane On 23 July 2014 15:56, Randy Dunlap wrote: > > [adding

Re: network interfaces called all, default or config

2014-08-14 Thread Stephane Chazelas
) = ? vconfig rem: socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 3 ioctl(3, SIOCSIFVLAN, 0x7fff67a00110) = 0 Cheers, Stephane On 23 July 2014 15:56, Randy Dunlap rdun...@infradead.org wrote: [adding netdev] On 07/23/2014 04:33 AM, Stephane Chazelas wrote: Hiya, you may want

network interfaces called "all", "default" or "config"

2014-07-23 Thread Stephane Chazelas
Hiya, you may want to forbid the creation of interfaces whose name is one of the special files in /proc/net and /proc/sys. I can see some characters (like space, tab, newline, slash, dot...) are alread forbidden in interface names (EINVAL), but one can do for instance: sudo ip link add link

network interfaces called all, default or config

2014-07-23 Thread Stephane Chazelas
Hiya, you may want to forbid the creation of interfaces whose name is one of the special files in /proc/net and /proc/sys. I can see some characters (like space, tab, newline, slash, dot...) are alread forbidden in interface names (EINVAL), but one can do for instance: sudo ip link add link

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-20 18:22:50 +0100, Jörn Engel: > On Wed, 20 February 2008 17:02:31 +0000, Stephane Chazelas wrote: > > > > sorry, I wasn't very clear. > > > > With "loop", you're doing an ioctl() to /dev/loop so that > > /dev/loop become a block device asso

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-20 17:30:42 +0100, Jörn Engel: > On Wed, 20 February 2008 14:43:39 +0000, Stephane Chazelas wrote: > > > > note that for "loop", you have /dev/loop0, /dev/loop1... which > > makes it a pain to handle > > > > For block2mtd, you don't need seve

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-20 17:42:27 +0100, Jörn Engel: > On Wed, 20 February 2008 14:36:46 +0000, Stephane Chazelas wrote: > > > > At the moment, when we bind a mtd device to a block device, we > > don't increase the refcount. When a mtdblock on a block2mtd, the > > refco

[PATCH 2.6.25-rc2] block2mtd: logging typo fixes

2008-02-20 Thread Stephane Chazelas
Hi joern, this patch addresses a number of small issues mainly regarding the output made by this driver to dmesg: - Some of the blkmtd's had not been changed to block2mtd which caused display problem - the parse_err() macro was displaying "block2mtd: " twice Signed-off-by

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-19 23:33:38 +0100, Arnd Bergmann: > On Tuesday 19 February 2008, you wrote: > > > What about having a /dev/block2mtd (with owner/permissions that > > > could allow non-root users to use it), with 2 ioctls: > > > > > > - one to "link" a block dev to a mtd that would take as > > >  

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-19 16:08:22 +0100, Jörn Engel: > [ Just returned home. ] Hi Jörn, I've got to admit I've been a little too busy to look at it myself. I'll send a patch for the obvious fixes soon though. [...] > > Well, yes that raised a concern to me, the "exit" function > > returns "void". If the

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-19 23:33:38 +0100, Arnd Bergmann: On Tuesday 19 February 2008, you wrote: What about having a /dev/block2mtd (with owner/permissions that could allow non-root users to use it), with 2 ioctls: - one to link a block dev to a mtd that would take as   parameter a fd to an open

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-19 16:08:22 +0100, Jörn Engel: [ Just returned home. ] Hi Jörn, I've got to admit I've been a little too busy to look at it myself. I'll send a patch for the obvious fixes soon though. [...] Well, yes that raised a concern to me, the exit function returns void. If the

[PATCH 2.6.25-rc2] block2mtd: logging typo fixes

2008-02-20 Thread Stephane Chazelas
Hi joern, this patch addresses a number of small issues mainly regarding the output made by this driver to dmesg: - Some of the blkmtd's had not been changed to block2mtd which caused display problem - the parse_err() macro was displaying block2mtd: twice Signed-off-by: Stephane

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-20 17:30:42 +0100, Jörn Engel: On Wed, 20 February 2008 14:43:39 +, Stephane Chazelas wrote: note that for loop, you have /dev/loop0, /dev/loop1... which makes it a pain to handle For block2mtd, you don't need several device files in /dev, you only need one to pass

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-20 18:22:50 +0100, Jörn Engel: On Wed, 20 February 2008 17:02:31 +, Stephane Chazelas wrote: sorry, I wasn't very clear. With loop, you're doing an ioctl() to /dev/loopx so that /dev/loopx become a block device associated with a given file. Applying that strictly

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-20 Thread Stephane Chazelas
2008-02-20 17:42:27 +0100, Jörn Engel: On Wed, 20 February 2008 14:36:46 +, Stephane Chazelas wrote: At the moment, when we bind a mtd device to a block device, we don't increase the refcount. When a mtdblock on a block2mtd, the refcount is not increased either (the mtdblock's one

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-12 Thread Stephane Chazelas
2008-02-12 16:21:24 +0100, Jörn Engel: > On Tue, 12 February 2008 13:47:51 +0000, Stephane Chazelas wrote: > > > > this patch addresses a number of small issues mainly regarding > > the output made by this driver to dmesg: > > - Some of the "blkmtd"

[PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-12 Thread Stephane Chazelas
he cabability with: echo /dev/loop3,remove | sudo tee /sys/module/block2mtd/parameters/block2mtd Signed-off-by: Stephane Chazelas <[EMAIL PROTECTED]> --- drivers/mtd/devices/block2mtd.c~2007-09-11 03:50:29.0 +0100 +++ drivers/mtd/devices/block2mtd.c 2008-02-12 13:30:16.00

Re: [PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-12 Thread Stephane Chazelas
2008-02-12 16:21:24 +0100, Jörn Engel: On Tue, 12 February 2008 13:47:51 +, Stephane Chazelas wrote: this patch addresses a number of small issues mainly regarding the output made by this driver to dmesg: - Some of the blkmtd's had not been changed to block2mtd which caused

[PATCH 2.6.24] block2mtd: removing a device and typo fixes

2008-02-12 Thread Stephane Chazelas
,remove | sudo tee /sys/module/block2mtd/parameters/block2mtd Signed-off-by: Stephane Chazelas [EMAIL PROTECTED] --- drivers/mtd/devices/block2mtd.c~2007-09-11 03:50:29.0 +0100 +++ drivers/mtd/devices/block2mtd.c 2008-02-12 13:30:16.0 + @@ -305,7 +305,7 @@ static struct