lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4665DC96.8020100@trash.net>
Date:	Tue, 05 Jun 2007 23:58:46 +0200
From:	Patrick McHardy <kaber@...sh.net>
To:	Ben Greear <greearb@...delatech.com>
CC:	netdev@...r.kernel.org
Subject: Re: [RFC VLAN 10/10]: Use rtnl_link API

Ben Greear wrote:
> Patrick McHardy wrote:
> 
>> [VLAN]: Use rtnl_link API
>>
>> Signed-off-by: Patrick McHardy <kaber@...sh.net>
> 
> 
>> +static int vlan_newlink(struct net_device *dev,
>> +            struct nlattr *tb[], struct nlattr *data[])
>> +{
>> +    struct vlan_dev_info *vlan = VLAN_DEV_INFO(dev);
>> +    int err;
>> +
>> +    if (!tb[IFLA_LINK])
>> +        return -EINVAL;
>> +    if (!data[IFLA_VLAN_ID])
>> +        return -EINVAL;
>> +
>> +    vlan->vlan_id  = nla_get_u16(data[IFLA_VLAN_ID]);
>> +    vlan->real_dev = __dev_get_by_index(nla_get_u32(tb[IFLA_LINK]));
> 
> 
> It seems you are scribbling on dev->priv before you validate that
> it is OK to do so?
> 
> Or, maybe I'm just confused.
> 
> What is 'dev' here?


Its a newly created device, not registered at this point. The
vlan_dev_info structure is used to communicate the settings
to vlan_dev_init() (also by the ioctl wrapper).

> Other than this, this patch and the others in this series
> look fine (except for the 4095 VID issue that we communicated
> about earlier).


Thanks, I'll fix that, add the remaining bits, and repost.
I think its only REORDER_HDR support that is still missing.

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ