From patchwork Thu Nov 22 02:52:01 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Chen Gang X-Patchwork-Id: 201113 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 5218F2C007B for ; Fri, 23 Nov 2012 05:41:26 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754900Ab2KVSkN (ORCPT ); Thu, 22 Nov 2012 13:40:13 -0500 Received: from intranet.asianux.com ([58.214.24.6]:39735 "EHLO intranet.asianux.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754836Ab2KVSkH (ORCPT ); Thu, 22 Nov 2012 13:40:07 -0500 Received: by intranet.asianux.com (Postfix, from userid 103) id 6FBA61840266; Thu, 22 Nov 2012 10:51:21 +0800 (CST) X-Spam-Score: -100.8 X-Spam-Checker-Version: SpamAssassin 3.1.9 (2007-02-13) on intranet.asianux.com X-Spam-Level: X-Spam-Status: No, score=-100.8 required=5.0 tests=AWL,BAYES_00, RATWARE_GECKO_BUILD,USER_IN_WHITELIST autolearn=no version=3.1.9 Received: from [192.168.50.2] (unknown [219.143.36.82]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by intranet.asianux.com (Postfix) with ESMTP id 0FEDD1840256; Thu, 22 Nov 2012 10:51:06 +0800 (CST) Message-ID: <50AD9351.5020805@asianux.com> Date: Thu, 22 Nov 2012 10:52:01 +0800 From: Chen Gang User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120911 Thunderbird/15.0.1 MIME-Version: 1.0 To: Shan Wei , Eric Dumazet CC: David Miller , netdev Subject: Re: [PATCH] net: ipv6: change %8s to %s for rt->dst.dev->name in seq_printf of rt6_info_route Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Hi Shan Wei, Eric Dumazet is this patch integrated into main branch ? if need me for additional completion (such as: merge another 2 trivial patches into this patch, too) please tell me, I will do. I understand you are working overtime, maybe no time for any minor and trivial patches. if surely it is, I think: you can modify these code manually, and obsolete these minor and trivial patches which I provided. I do not mind whether mention me in another new patches (you can mention me or not mention me, both are OK). since our goal is to provide contributes to outside, efficiently. regards gchen 于 2012年11月05日 11:02, Chen Gang 写道: > > 1. not to send same patch triple times. thanks, I shall notice, next time. (I shall 'believe' another members). > 2. config your email client,because tab is changed to space. > you can read Documentation/email-clients.txt. 1) thanks. I shall notice, next time. 2) now, I get gvim as extention editor for thounderbird 3) the patch is generated by `git format-patch -s --summary --stat` it use "' '\t" as head, I do not touch it, maybe it is correct. welcome any members to giving additional suggestions and completions. thanks the modified contents are below, ----------------------------------------------------------------------------------- the length of rt->dst.dev->name is 16 (IFNAMSIZ) in seq_printf, it is not suitable to use %8s for rt->dst.dev->name. so change it to %s, since each line has not been solid any more. additional information: %8s limit the width, not for the original string output length if name length is more than 8, it still can be fully displayed. if name length is less than 8, the ' ' will be filled before name. %.8s truly limit the original string output length (precision) Signed-off-by: Chen Gang --- net/ipv6/route.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/net/ipv6/route.c b/net/ipv6/route.c index c42650c..b60bc52 100644 --- a/net/ipv6/route.c +++ b/net/ipv6/route.c @@ -2835,7 +2835,7 @@ static int rt6_info_route(struct rt6_info *rt, void *p_arg) } else { seq_puts(m, "00000000000000000000000000000000"); } - seq_printf(m, " %08x %08x %08x %08x %8s\n", + seq_printf(m, " %08x %08x %08x %08x %s\n", rt->rt6i_metric, atomic_read(&rt->dst.__refcnt), rt->dst.__use, rt->rt6i_flags, rt->dst.dev ? rt->dst.dev->name : "");