Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp827956imu; Mon, 5 Nov 2018 09:20:30 -0800 (PST) X-Google-Smtp-Source: AJdET5cUucBRrfMSn9DElBgsi+Dhn62GUNW6alMvwFcnzMujU7ym9eBSLe1IPEqgqg3yNE5LOX6u X-Received: by 2002:a62:8d92:: with SMTP id p18-v6mr23498857pfk.217.1541438430158; Mon, 05 Nov 2018 09:20:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541438430; cv=none; d=google.com; s=arc-20160816; b=GCQRGA+atNTaav3DRRoOPQpsCYRnx0ePoDpODo45n9MPN1geF3v8QSg+91f4SSws+8 4RFWH2mrgYDI1BTlz6zrrqm7ulcNiLa9uAsyxRthNiYn1S8qBRtneLqjS6TX/GHxbBVe DkShRd8fVZxJXsWu2Vahk32eVjXsLd5Gvg0DvBPdRagGVZWKo7QG75Eo35O3+A0Y3Z+q 222omZr4EuyaBSRng2AnNBgAYpDTBenSYIRvOcWdupmGF84SVtmDI+t8tOFR16L4euxr hTwxzevcE6UAESFc0SB5qN00a1MvvsD03f1vy7oWc12SP6AXgtcuEvIvQ46qcsmzZLf7 IwVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=yeqCh/RL/DBT9DzwrUpxA2QCznWJ3GvMbgliS2owqF0=; b=esyAaPBfQDKU5Lmfb8F3aMvGZWulpTIU/RJT3g2Qt4PMA4Af0MnAhZcxfMmdTPsyBS 5IPvKWbtCTUc2kaA5VAF1ack3TcJTfp7Wt9LBYmaD/j+cWRGMo4Ymk1z9EA+W8NX0EnR oYzePEfMpaJja9ppwUdkynJX5ywpPcfb6kIm7dzV3gzqcPbPnqdmbAl84lXFW1yT/E/J 9A3c+cXvgqVDQoQ3FQevjDi+J66bUQyRA+RkyHgCLwXofN732zTesbDey5nNG1Z/dwh9 I6jsTUJcCtkPQ0l1HBv7XgB8kZ55Qfq4KZOXQcB7two4SsQohbqSknzgRejn9MLEhjao pCow== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g9-v6si42385680plo.328.2018.11.05.09.20.11; Mon, 05 Nov 2018 09:20:30 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387657AbeKFCkQ (ORCPT + 99 others); Mon, 5 Nov 2018 21:40:16 -0500 Received: from mail-vs1-f67.google.com ([209.85.217.67]:40090 "EHLO mail-vs1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387458AbeKFCkP (ORCPT ); Mon, 5 Nov 2018 21:40:15 -0500 Received: by mail-vs1-f67.google.com with SMTP id s9so5563152vsk.7; Mon, 05 Nov 2018 09:19:35 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=yeqCh/RL/DBT9DzwrUpxA2QCznWJ3GvMbgliS2owqF0=; b=PRvK0lsKEiGYbNKCxvYnuyvd4kC4q2nzMN4pGxmQiW6YJVIcHkgigR5n68BJVqcJwg 3KlDWpwEYHnP6mbELn4wnF3CCA/GPqnWmOPHFm9cGH5vhOo/fb9Nz+ng0WpP9gCmj5Tt yvGABwS9orTS7O+hvg2OYvB2VUYh2yzI5vQs91zKsDZcHLG6fQF8ZK8/DbRUjKo9cU+i rL4ITYw27tzAzC73WTss/T7KXi6lJ+DpJOF5u6AJ5k68NIGQX/JJpN823+IxhpfBOUp0 hpEAG4xnu8hxhrOdoIm6qaDLDN/RXMxydw+2t7o5Kp+G1q8+svrt8vtYHBQmlLrt0ut6 +eLA== X-Gm-Message-State: AGRZ1gIamGs2/Xt0pc1G1Xlod+rsh04pawDDs4lM8rZaT+mYLltISsa/ bbuWVJllQ8FEyUTTtYZfH7CIamT6xjnYQG1b+cHLmWsZ X-Received: by 2002:a67:3885:: with SMTP id n5mr6499579vsi.96.1541438374474; Mon, 05 Nov 2018 09:19:34 -0800 (PST) MIME-Version: 1.0 References: <1540836824-4636-1-git-send-email-jacopo+renesas@jmondi.org> In-Reply-To: <1540836824-4636-1-git-send-email-jacopo+renesas@jmondi.org> From: Geert Uytterhoeven Date: Mon, 5 Nov 2018 18:19:22 +0100 Message-ID: Subject: Re: [PATCH 0/2] pinctrl: sh-pfc: r8a77965: Add VIN4 and VIN5 To: Jacopo Mondi Cc: Geert Uytterhoeven , Laurent Pinchart , Simon Horman , Linus Walleij , Linux-Renesas , "open list:GPIO SUBSYSTEM" , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Jacopo, On Mon, Oct 29, 2018 at 7:14 PM Jacopo Mondi wrote: > this two patches add supports for VIN4 and VIN5 interfaces to R-Car M3-N. > > On this SoC (and in the forthcoming support for E3 R8A77990) the VIN groups > could appear on different sets of pins, usually the 'a' and 'b' one. > > With the existing VIN_DATA_PIN_GROUP macro we have to specify group names as: > > VIN_DATA_PIN_GROUP(vin4_data_a, 8) > > which results in the group being named as "vin4_data_a_8" which is > un-consistent with the canonical group names (eg. "vin4_data8_a"). > > This series adds a macro that allows to specify the group 'version' along with > the pin and mux numbers in patch [1/1]. I haven't been able to find a better > term than 'version' as 'group' was already taken. Suggestions welcome. Yeah, the datasheet also calls these groups :-( A possible alternative is to use "variant"? Or, what about avoiding the name issue by making the VIN_DATA_PIN_GROUP() macro varargs, and passing the "variant" as the (optional) third parameter? That way existing users work as a before, while you can also write e.g. VIN_DATA_PIN_GROUP_VER(vin4_data, 8, _a), > As I cannot test VIN4 nor VIN5 on Salvator-XS as the parallel pins are not > wired, I made sure the macro creates correct names and fields not only by > compile testing it, but with a small C program [1] that replicates the VIN data > layout defined in the PFC module and access fields (and has helped me testing > more easily the preprocessor stringification/concatenation process). > > Final note: Simon, you took the E3 patches in your tree, and I expect them to > land on v4.20-rc1. They use the old macros, are follow up patches ok?) Which patches are using these macro names, and are in v4.20-rc1? BTW, "grep vin._data_[a-z][0-9] drivers/pinctrl/sh-pfc/*o" tells me we already have broken groups names on r8a7792, r8a7795, and r8a7796. Fortunately we have no known users of them, so they can be fixed. Thanks! Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds