lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Tue, 25 Jul 2023 16:27:29 +0800
From:   Hal Feng <hal.feng@...rfivetech.com>
To:     Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
        Mark Brown <broonie@...nel.org>,
        Liam Girdwood <lgirdwood@...il.com>,
        Jaroslav Kysela <perex@...ex.cz>,
        Takashi Iwai <tiwai@...e.com>,
        Rob Herring <robh+dt@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Conor Dooley <conor@...nel.org>,
        "Walker Chen" <walker.chen@...rfivetech.com>,
        Xingyu Wu <xingyu.wu@...rfivetech.com>,
        Emil Renner Berthing <emil.renner.berthing@...onical.com>
CC:     <alsa-devel@...a-project.org>, <devicetree@...r.kernel.org>,
        <linux-riscv@...ts.infradead.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v1 1/5] ASoC: dt-bindings: Add StarFive JH7110 dummy
 PWM-DAC transmitter

On Mon, 10 Jul 2023 11:22:50 +0800, Hal Feng wrote:
> On Sat, 1 Jul 2023 10:17:51 +0200, Krzysztof Kozlowski wrote:
>> On 30/06/2023 03:57, Hal Feng wrote:
>>> On Mon, 26 Jun 2023 17:34:56 +0200, Krzysztof Kozlowski wrote:
>>>> On 26/06/2023 13:09, Hal Feng wrote:
>>>>> Add bindings for StarFive JH7110 dummy PWM-DAC transmitter.
>>>>
>>>> ...
>>>>
>>>>> +required:
>>>>> +  - compatible
>>>>> +  - "#sound-dai-cells"
>>>>> +
>>>>> +additionalProperties: false
>>>>> +
>>>>> +examples:
>>>>> +  - |
>>>>> +    pwmdac-dit {
>>>>> +        compatible = "starfive,jh7110-pwmdac-dit";
>>>>> +        #sound-dai-cells = <0>;
>>>>
>>>> BTW, I don't see any resources here. Neither in the driver. I think you
>>>> just added this for driver, not for a real hardware.
>>> 
>>> Yes, this is a dummy PWM-DAC transmitter as described in the title. The
>>> StarFive JH7110 PWM-DAC module doesn't need a hardware codec, but a
>>> dummy codec is needed for the driver.
>> 
>> Bindings are no for drivers, therefore with such reasoning the answer
>> is: drop entire binding. If you think otherwise, please give me some
>> more details about the hardware.
> 
> I agreed. I will drop this binding and the compatible in patch 2. Thanks.

Hi, Krzysztof,

Could I use the dummy spdif codec [1][2] which is already upstream? The dummy
spdif codec is really compatible with the one which JH7110 PWM-DAC needed.
They are mostly similar.

[1] Documentation/devicetree/bindings/sound/linux,spdif-dit.yaml
[2] sound/soc/codecs/spdif_transmitter.c

In that way, patch 1 & 2 can be dropped and patch 5 will be modified as follows.

+	pwmdac_dit: pwmdac-dit {
+		compatible = "linux,spdif-dit";
+		#sound-dai-cells = <0>;
+	};
+
+	sound {
+		compatible = "simple-audio-card";
+		simple-audio-card,name = "StarFive-PWMDAC-Sound-Card";
+		#address-cells = <1>;
+		#size-cells = <0>;
+
+		simple-audio-card,dai-link@0 {
+			reg = <0>;
+			format = "left_j";
+			bitclock-master = <&sndcpu0>;
+			frame-master = <&sndcpu0>;
+
+			sndcpu0: cpu {
+				sound-dai = <&pwmdac>;
+			};
+
+			codec {
+				sound-dai = <&pwmdac_dit>;
+			};
+		};
+	};

Best regards,
Hal

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ