[{"id":3684648,"web_url":"http://patchwork.ozlabs.org/comment/3684648/","msgid":"<CAD++jLk43uWNojmajzKUGm-UzP8Z7qxC2nwMrRE6=WVbTt=-Ww@mail.gmail.com>","list_archive_url":null,"date":"2026-04-30T12:08:15","subject":"Re: [PATCH v2 1/2] dt-bindings: gpio: fairchild,74hc595: add\n lines-initial-states property","submitter":{"id":92050,"url":"http://patchwork.ozlabs.org/api/people/92050/","name":"Linus Walleij","email":"linusw@kernel.org"},"content":"On Wed, Apr 29, 2026 at 5:51 AM Chanhong Jung <happycpu@gmail.com> wrote:\n\n> The 74HC595 and 74LVC594 shift registers latch their outputs until the\n> first serial write, so boards that depend on a specific power-on pattern\n> (for example active-low indicators, reset lines, or other signals that\n> must come up non-zero) have no way to express that today: the Linux\n> driver always writes zeros from its zero-initialised buffer during\n> probe.\n>\n> Document support for the existing lines-initial-states bitmask, already\n> defined for nxp,pcf8575, so the same convention covers this output-only\n> device. Bit N corresponds to GPIO line N. Because the 74HC595/74LVC594\n> family is push-pull output only (no input mode, no high-impedance state\n> under software control), bit=0 drives the line low and bit=1 drives it\n> high; this differs from nxp,pcf8575, where the 0/1 polarity reflects the\n> quasi-bidirectional nature of that part.\n>\n> The bitmask covers up to 32 lines, which fits the typical 1-4 chip\n> cascades that appear in tree. Should longer chains require seeding in\n> the future, the property can be extended to a uint32-array without\n> breaking the bit-N-equals-line-N convention.\n>\n> Suggested-by: Linus Walleij <linus.walleij@linaro.org>\n\nMy old email but who cares.\n\n> Signed-off-by: Chanhong Jung <happycpu@gmail.com>\n\nThis works for me.\nReviewed-by: Linus Walleij <linusw@kernel.org>\n\nYours,\nLinus Walleij","headers":{"Return-Path":"\n <linux-gpio+bounces-35911-incoming=patchwork.ozlabs.org@vger.kernel.org>","X-Original-To":["incoming@patchwork.ozlabs.org","linux-gpio@vger.kernel.org"],"Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256\n header.s=k20201202 header.b=mXFyrHDV;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=2600:3c0a:e001:db::12fc:5321; helo=sea.lore.kernel.org;\n envelope-from=linux-gpio+bounces-35911-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)","smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org\n header.b=\"mXFyrHDV\"","smtp.subspace.kernel.org;\n arc=none smtp.client-ip=10.30.226.201"],"Received":["from sea.lore.kernel.org (sea.lore.kernel.org\n [IPv6:2600:3c0a:e001:db::12fc:5321])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g5tLP1cRnz1xqf\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 30 Apr 2026 22:11:09 +1000 (AEST)","from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby sea.lore.kernel.org (Postfix) with ESMTP id 293D53009B14\n\tfor <incoming@patchwork.ozlabs.org>; Thu, 30 Apr 2026 12:08:30 +0000 (UTC)","from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id 4B471401A2E;\n\tThu, 30 Apr 2026 12:08:29 +0000 (UTC)","from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org\n [10.30.226.201])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id 0DA303FFADC\n\tfor <linux-gpio@vger.kernel.org>; Thu, 30 Apr 2026 12:08:28 +0000 (UTC)","by smtp.kernel.org (Postfix) with ESMTPSA id B7025C2BCB3\n\tfor <linux-gpio@vger.kernel.org>; Thu, 30 Apr 2026 12:08:28 +0000 (UTC)","by mail-lf1-f52.google.com with SMTP id\n 2adb3069b0e04-5a40cfab24dso934513e87.2\n        for <linux-gpio@vger.kernel.org>;\n Thu, 30 Apr 2026 05:08:28 -0700 (PDT)"],"ARC-Seal":"i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1777550909; cv=none;\n b=txIWvO3VQszK47P5RzQKTh65lRXQ2s/cuQLo4kenyR9/SUQgS4hww2hlmc1+Bbq052g9tXWIoBqdhj+A+J9eTaW37n/B05etBwZaTLC/cnjy99AJ1bhaUThM9aVihfhg3YZvWf+pYF+rwpgsqWUKrlLbZtRjHHtMrPq3R8nJkdE=","ARC-Message-Signature":"i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1777550909; c=relaxed/simple;\n\tbh=Z0SrwckcmMEhYsq872vQn8z1xxHWcTPFIyYdkrVQ7t0=;\n\th=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject:\n\t To:Cc:Content-Type;\n b=b78vAnvyJZ8TMvH6Hqm0EGu2PQjGixnx0DhuQauS+EVFco2W2juEW7a+qUT3bxHQWd/BFH9FSK+aaH+Z9j/+NIE5aMFaBMCCztMLefLEzpSpcDZu3uJ9HRFM+NQVzIJWBxGQK5ntBqlHGmwXSx+Qro34Ru9CEek3OajpLnnRKCo=","ARC-Authentication-Results":"i=1; smtp.subspace.kernel.org;\n dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org\n header.b=mXFyrHDV; arc=none smtp.client-ip=10.30.226.201","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org;\n\ts=k20201202; t=1777550908;\n\tbh=Z0SrwckcmMEhYsq872vQn8z1xxHWcTPFIyYdkrVQ7t0=;\n\th=References:In-Reply-To:From:Date:Subject:To:Cc:From;\n\tb=mXFyrHDVW4CzmTPPXSkWX6ArMnD83/YLIYYNUXvi6hTeGxU8w1aZEMreLS+LlFeuz\n\t JNjSrJxdsoUruqZyDNVoF3x8r6vW7lWkoS37KDkqf2xZjtgLEeWHqGBxj9PRKj71DI\n\t rNpIML4FsvMecBomBPQ+nvWg1W7brrNDYjRr13tkrnqHvzwQL1R2CLPqAW5lK9KdC0\n\t 74Fajb3bOmjJZPQSVV/E14I1CmAhXqUd1jAjcYvuYH2xTOnjqVIv+cVIWAjS29k5/j\n\t fvbV6zUeC2YLdDNeF/8z38rzq3cIoXkqmIwpT4vQCbVBx9pRUus60EfwYcVweVJiRX\n\t +XwMJ0hyNuEYg==","X-Forwarded-Encrypted":"i=1;\n AFNElJ9pG6Nxo3aUSnqHy9UG7FE2BmOhB7PZLVKuBCd+ggWMGa6oF5kzoBPGEpoY+reSSOEvsD+n1koY1OGB@vger.kernel.org","X-Gm-Message-State":"AOJu0YyxKFs06uBpsQ24Bifm/RORfrXxemxVNUiK26DSVeViyKOA7Hyf\n\tHWBMGGL7JsygShwiKKlqLjYbm8H19dG7cS1Y2SbgqrI47IARBAAESqPoGTJC2kn9NaEfMlltMXA\n\twDumBHNehOf44FPyM/vOEsBFN+b2y+xQ=","X-Received":"by 2002:a05:6512:1394:b0:5a4:1798:31ba with SMTP id\n 2adb3069b0e04-5a8522d4e93mr847311e87.21.1777550907436; Thu, 30 Apr 2026\n 05:08:27 -0700 (PDT)","Precedence":"bulk","X-Mailing-List":"linux-gpio@vger.kernel.org","List-Id":"<linux-gpio.vger.kernel.org>","List-Subscribe":"<mailto:linux-gpio+subscribe@vger.kernel.org>","List-Unsubscribe":"<mailto:linux-gpio+unsubscribe@vger.kernel.org>","MIME-Version":"1.0","References":"<cover.1776872453.git.happycpu@gmail.com>\n <20260429035134.1023330-2-happycpu@gmail.com>","In-Reply-To":"<20260429035134.1023330-2-happycpu@gmail.com>","From":"Linus Walleij <linusw@kernel.org>","Date":"Thu, 30 Apr 2026 14:08:15 +0200","X-Gmail-Original-Message-ID":"\n <CAD++jLk43uWNojmajzKUGm-UzP8Z7qxC2nwMrRE6=WVbTt=-Ww@mail.gmail.com>","X-Gm-Features":"AVHnY4I0ki9rGDzmVa6bSPlog4a2U1FZNKcs6D7nH0y5brqxdc8g0KW-DN9bc0E","Message-ID":"\n <CAD++jLk43uWNojmajzKUGm-UzP8Z7qxC2nwMrRE6=WVbTt=-Ww@mail.gmail.com>","Subject":"Re: [PATCH v2 1/2] dt-bindings: gpio: fairchild,74hc595: add\n lines-initial-states property","To":"Chanhong Jung <happycpu@gmail.com>","Cc":"Bartosz Golaszewski <brgl@kernel.org>, Rob Herring <robh@kernel.org>,\n\tKrzysztof Kozlowski <krzk+dt@kernel.org>, Conor Dooley <conor+dt@kernel.org>,\n\tMaxime Ripard <mripard@kernel.org>, linux-gpio@vger.kernel.org,\n devicetree@vger.kernel.org,\n\tlinux-kernel@vger.kernel.org","Content-Type":"text/plain; charset=\"UTF-8\"","Content-Transfer-Encoding":"quoted-printable"}}]