Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1676976
| From | Jiri Benc <jbenc@redhat.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH net-next 2/2] vxlan: add back error messages to vxlan_config_validate() as extended netlink acks |
| Date | 2017-06-28 20:00 +0200 |
| Message-ID | <tXpq3-t5-183@gated-at.bofh.it> (permalink) |
| References | <tX5AT-5JN-39@gated-at.bofh.it> <tX5AT-5JN-37@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Tue, 27 Jun 2017 22:47:58 +0200, Matthias Schiffer wrote:
> if ((conf->flags & ~VXLAN_F_ALLOWED_GPE) ||
> !(conf->flags & VXLAN_F_COLLECT_METADATA)) {
> + NL_SET_ERR_MSG(extack,
> + "unsupported combination of extensions");
Since we're redesigning this, let's be more helpful to the user.
There's probably not going to be tremendous improvements here but let's
try at least a bit.
"VXLAN GPE does not support this combination of extensions"
> if (local_type & IPV6_ADDR_LINKLOCAL) {
> if (!(remote_type & IPV6_ADDR_LINKLOCAL) &&
> - (remote_type != IPV6_ADDR_ANY))
> + (remote_type != IPV6_ADDR_ANY)) {
> + NL_SET_ERR_MSG(extack,
> + "invalid combination of address scopes");
"invalid combination of local and remote address scopes"
> return -EINVAL;
> + }
>
> conf->flags |= VXLAN_F_IPV6_LINKLOCAL;
> } else {
> if (remote_type ==
> - (IPV6_ADDR_UNICAST | IPV6_ADDR_LINKLOCAL))
> + (IPV6_ADDR_UNICAST | IPV6_ADDR_LINKLOCAL)) {
> + NL_SET_ERR_MSG(extack,
> + "invalid combination of address scopes");
ditto
The rest looks good to me. Thanks a lot for doing the work, Matthias!
Jiri
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH net-next 2/2] vxlan: add back error messages to vxlan_config_validate() as extended netlink acks Matthias Schiffer <mschiffer@universe-factory.net> - 2017-06-27 22:50 +0200 Re: [PATCH net-next 2/2] vxlan: add back error messages to vxlan_config_validate() as extended netlink acks Jiri Benc <jbenc@redhat.com> - 2017-06-28 20:00 +0200
csiph-web