Re: [PATCH v2 2/2] mmc: mtk-sd: add support for AN7581 MMC Host

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jan 21, 2025 at 08:59:19AM +0100, Krzysztof Kozlowski wrote:
> On Mon, Jan 20, 2025 at 07:47:02PM +0100, Christian Marangi wrote:
> > -			pinctrl_select_state(host->pinctrl, host->pins_uhs);
> > +			/* Skip setting uhs pins if not supported */
> > +			if (host->pins_uhs)
> > +				pinctrl_select_state(host->pinctrl, host->pins_uhs);
> >  		} else {
> >  			dev_pm_clear_wake_irq(host->dev);
> >  		}
> > @@ -2816,9 +2835,12 @@ static int msdc_of_clock_parse(struct platform_device *pdev,
> >  	if (IS_ERR(host->src_clk))
> >  		return PTR_ERR(host->src_clk);
> >  
> > -	host->h_clk = devm_clk_get(&pdev->dev, "hclk");
> > -	if (IS_ERR(host->h_clk))
> > -		return PTR_ERR(host->h_clk);
> > +	/* AN7581 SoC doesn't have hclk */
> > +	if (!device_is_compatible(&pdev->dev, "airoha,an7581-mmc")) {
> 
> Please avoid coding compatible in multiple places. Not only because
> above check is slow comparing to check on integer, but it just scales
> poorly and leads to less readable further code. Use driver data with
> model name or flags/quirks bitmask.
>

I implemented this in a more compatible way so we don't need an
additional compatible anymore. Soo this series is not needed anymore.

Should I flag these as not applicable anywhere in the patchwork systems?

-- 
	Ansuel




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux