From patchwork Tue May 19 12:38:30 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yousong Zhou X-Patchwork-Id: 473895 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 7CBB2140D4D for ; Tue, 19 May 2015 22:52:22 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=itUKs49W; dkim-atps=neutral Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 86CF228C07B; Tue, 19 May 2015 14:48:49 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAYES_00,FREEMAIL_FROM, T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id B37DE28BE0C for ; Tue, 19 May 2015 14:48:34 +0200 (CEST) X-policyd-weight: using cached result; rate: -8.5 Received: from mail-pa0-f50.google.com (mail-pa0-f50.google.com [209.85.220.50]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Tue, 19 May 2015 14:48:32 +0200 (CEST) Received: by pabts4 with SMTP id ts4so23246581pab.3 for ; Tue, 19 May 2015 05:49:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=UkbpmfcnKzaQlE03gtK+67ovaJdly7pDRuFbj0vl4Bc=; b=itUKs49WnSr8KEbm/u/3OM/oKj79Oam0GTaLwW/qgjC2pkObhI+TJk6gUohTPm2Zni 5kFMzcV0gkUOESpPeELnEqmY0WE0lmi9uBTxstnBNt/j05ZubFLKmnQQqZFr6OHRVfOm fcCXJl9mlglQTL2JwmlCRn1MTISfjikME5dfAkNSS+KiMa9VP3Zds8Pk3Py5uWE2+KdA A6QOkQjRVa74bx5FBLEdI/AebRpZFsqYi6BAt3jf4vlX3T7UuYeRM4RIfe5cj3iED+l5 MySQU6yeQLTC8D9mjtdlfl3qomoJ6ZJv2XDjJambL4kfc23HuXAqfARSx0OSe+zIJr+0 scMg== X-Received: by 10.70.133.66 with SMTP id pa2mr54460297pdb.164.1432039789519; Tue, 19 May 2015 05:49:49 -0700 (PDT) Received: from debian.corp.sankuai.com ([103.29.140.56]) by mx.google.com with ESMTPSA id oj10sm13091283pdb.38.2015.05.19.05.49.46 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 19 May 2015 05:49:48 -0700 (PDT) From: Yousong Zhou To: nbd@openwrt.org Date: Tue, 19 May 2015 20:38:30 +0800 Message-Id: <1432039113-24136-4-git-send-email-yszhou4tech@gmail.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1432039113-24136-1-git-send-email-yszhou4tech@gmail.com> References: <1432039113-24136-1-git-send-email-yszhou4tech@gmail.com> Cc: openwrt-devel@lists.openwrt.org Subject: [OpenWrt-Devel] [PATCH 3/6] interface: remove redundant iface_attr_info. X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" BLOBMSG_TYPE_STRING is the default type for elements of BLOBMSG_TYPE_ARRAY. Array type IFACE_ATTR_DNS_SEARCH was already missing there, so drop the whole part anyway. Signed-off-by: Yousong Zhou --- interface.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/interface.c b/interface.c index 5b79ffc..9f6d8f0 100644 --- a/interface.c +++ b/interface.c @@ -68,15 +68,9 @@ static const struct blobmsg_policy iface_attrs[IFACE_ATTR_MAX] = { [IFACE_ATTR_FORCE_LINK] = { .name = "force_link", .type = BLOBMSG_TYPE_BOOL }, }; -static const struct uci_blob_param_info iface_attr_info[IFACE_ATTR_MAX] = { - [IFACE_ATTR_DNS] = { .type = BLOBMSG_TYPE_STRING }, - [IFACE_ATTR_IP6CLASS] = { .type = BLOBMSG_TYPE_STRING }, -}; - const struct uci_blob_param_list interface_attr_list = { .n_params = IFACE_ATTR_MAX, .params = iface_attrs, - .info = iface_attr_info, }; static void