The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Stefan Gula <steweg@ynet.sk>
To: "David S. Miller" <davem@davemloft.net>
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [patch v2, kernel 3.2.1] RTNETLINK adjusting values of min_ifinfo_dump_size
Date: Thu, 26 Jan 2012 22:01:06 +0100 (CET)	[thread overview]
Message-ID: <3280801.2791327611666778.JavaMail.root@5-MeO-DMT.ynet.sk> (raw)

From: Stefan Gula <steweg@gmail.com>

Setting link parameters on a netdevice changes the value
of if_nlmsg_size(), therefore it is necessary to recalculate
min_ifinfo_dump_size.

Signed-off-by: Stefan Gula <steweg@gmail.com>

---
V2-changelog: adjusted commit message

--- linux-3.2.1-orig/net/core/rtnetlink.c	2012-01-12 20:42:45.000000000 +0100
+++ linux/net/core/rtnetlink.c	2012-01-24 14:26:58.083219352 +0100
@@ -1506,6 +1506,9 @@ errout:
 
 	if (send_addr_notify)
 		call_netdevice_notifiers(NETDEV_CHANGEADDR, dev);
+	min_ifinfo_dump_size = max_t(u16, if_nlmsg_size(dev),
+					min_ifinfo_dump_size);
+
 	return err;
 }

             reply	other threads:[~2012-01-26 21:04 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-26 21:01 Stefan Gula [this message]
2012-01-26 21:37 ` [patch v2, kernel 3.2.1] RTNETLINK adjusting values of min_ifinfo_dump_size David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3280801.2791327611666778.JavaMail.root@5-MeO-DMT.ynet.sk \
    --to=steweg@ynet.sk \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox