From patchwork Fri Aug 4 14:59:34 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 109427 Delivered-To: patch@linaro.org Received: by 10.140.101.6 with SMTP id t6csp2268284qge; Fri, 4 Aug 2017 08:01:39 -0700 (PDT) X-Received: by 10.99.122.28 with SMTP id v28mr2670931pgc.98.1501858899131; Fri, 04 Aug 2017 08:01:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1501858899; cv=none; d=google.com; s=arc-20160816; b=EFokKYSoefoow+eQTZ0+umdSueHFDo2vNBVVhiHvWoKc4SIMxgc4kEgM4g7uHKILxW zPOQlTMvVp0aLchnTOBYpyiohmneJ9o9e+7mt84b76n4VgEvrj5jlnfk0hinptDlnwMQ s3JhozGHgTRLm1GsDMjeEcq8yThn7cQZbnVOsJqSxKzTxPK5lw3isYTSKhNtx2MCpuHl 8GOZJWCbRScyQfrEaz3S5c3SlAp5E3Y4hLJL8zn/2LLTeJvkTbdH6lkDlMNcIu3OulGg Qrg1mA2KGgzjikRA7Ybb399YJ1S0VbHZ5bHi6DzhG6kKdWFqSxuDOInIXngIRh97NUpW r3BA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=UIAkTxH7bhKIjO2JrMi1tXjpUUBVFMgn0Odw+Yx2bJU=; b=RmcbdGLl02XphOLmDavDTkcwgp2r7VC6z7LrweOpRq9WECUo11upKsxLOBFQf9UPmm 5rnIpbTfs9GltZeOccldUQpACjw4PyAysn10ibWjF+YpH9iSzvS7aKC2AXZKzHgXzuZT FgacgnB8TpttmXs3qW+x1xaE+YTDkMzszoPeLIhRdWTeo+WJ4CHcQ+645MbKu/MPvVHU 8J21mXTNX6L44kuXhHB+jKPTGBwDMjSl3wRcXtS2jSLP+aQPbvLY0vtDI5jZ/rITX2fV mo4fYD2VIicgxcv+3G9tmMTIdPP0Y7nWRj9zE4OH2dAcV/k3674MAD2x/muXNTM83Eew p6AA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.b=T8is1Pns; spf=pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g191si1090527pgc.563.2017.08.04.08.01.38; Fri, 04 Aug 2017 08:01:39 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.b=T8is1Pns; spf=pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752683AbdHDPBh (ORCPT + 6 others); Fri, 4 Aug 2017 11:01:37 -0400 Received: from mail-pf0-f169.google.com ([209.85.192.169]:35296 "EHLO mail-pf0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752669AbdHDO7q (ORCPT ); Fri, 4 Aug 2017 10:59:46 -0400 Received: by mail-pf0-f169.google.com with SMTP id t86so8915392pfe.2 for ; Fri, 04 Aug 2017 07:59:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=UIAkTxH7bhKIjO2JrMi1tXjpUUBVFMgn0Odw+Yx2bJU=; b=T8is1Pnske7XgCGl0KOAJB3tnH5gLyZCaOa+C2kJZaNK3IUMYcHp+26wLxGUOsUrq6 uSfxmwPE1onypnKvxSKOOMYyipDHqj+xsChqIOLf1/WLzp3Bq+96ramfb6zfYg/Vdam9 LUxGmj4094KlWie4bnla7kDhJ6f+zgcn4V3PM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=UIAkTxH7bhKIjO2JrMi1tXjpUUBVFMgn0Odw+Yx2bJU=; b=ZdGhwpZ4hoX200DNACV0l5bnM5UMPFJDAiO7X+8O7FTYAwwnBQX3x3DOHKiwd99EJ5 kYyPuPjF13/hT0Znl5orRU2GkoObtz+ogArEdNCw4D0YBFK+wpuat+reh16/c9qtOwwK w6PAv8zJB/Ltbd4wOpHsWeTcdioSIMKYmZkbSKeE926HSv57ubbFPzWyFruc0GtsPVNz PFjx/xktOpdd0SApmU7hvSQTCNQArLUH6+q7K0qvIMdlaV0JbFz4WtCk7xOuTCR1mbnO BT1LhHhmLxsDqVXE0NjMHsU3Io9bSv1EgZSBaIIlN0zHShv8LQlus7oVNmvf6CktmYXt LcbA== X-Gm-Message-State: AIVw112NyNwpiYkMqCuVVHklnp6BhhWgJx+LvU7vquJE6OspOMhHK+tD Eelk4qIsjPPFVrET X-Received: by 10.99.113.17 with SMTP id m17mr2543272pgc.343.1501858785485; Fri, 04 Aug 2017 07:59:45 -0700 (PDT) Received: from localhost.localdomain (ip68-111-217-79.sd.sd.cox.net. [68.111.217.79]) by smtp.gmail.com with ESMTPSA id q24sm3584283pgc.61.2017.08.04.07.59.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 04 Aug 2017 07:59:44 -0700 (PDT) From: Bjorn Andersson To: "David S. Miller" , Andy Gross , David Brown Cc: linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/6] net: qrtr: Move constants to header file Date: Fri, 4 Aug 2017 07:59:34 -0700 Message-Id: <20170804145938.25427-3-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20170804145938.25427-1-bjorn.andersson@linaro.org> References: <20170804145938.25427-1-bjorn.andersson@linaro.org> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org The constants are used by both the name server and clients, so make their value explicit and move them to the uapi header. Signed-off-by: Bjorn Andersson --- include/uapi/linux/qrtr.h | 3 +++ net/qrtr/qrtr.c | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-) -- 2.12.0 diff --git a/include/uapi/linux/qrtr.h b/include/uapi/linux/qrtr.h index 9d76c566f66e..63e8803e4d90 100644 --- a/include/uapi/linux/qrtr.h +++ b/include/uapi/linux/qrtr.h @@ -4,6 +4,9 @@ #include #include +#define QRTR_NODE_BCAST 0xffffffffu +#define QRTR_PORT_CTRL 0xfffffffeu + struct sockaddr_qrtr { __kernel_sa_family_t sq_family; __u32 sq_node; diff --git a/net/qrtr/qrtr.c b/net/qrtr/qrtr.c index 2058b27821a4..0d7d3968414e 100644 --- a/net/qrtr/qrtr.c +++ b/net/qrtr/qrtr.c @@ -61,8 +61,6 @@ struct qrtr_hdr { } __packed; #define QRTR_HDR_SIZE sizeof(struct qrtr_hdr) -#define QRTR_NODE_BCAST ((unsigned int)-1) -#define QRTR_PORT_CTRL ((unsigned int)-2) struct qrtr_sock { /* WARNING: sk must be the first member */