[PATCH RESEND net-next v6 2/7] net: stmmac: qcom-ethqos: use generic device properties
Andrew Lunn
andrew at lunn.ch
Mon Jan 12 05:44:49 PST 2026
On Mon, Jan 12, 2026 at 11:15:41AM +0100, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <brgl at kernel.org>
>
> In order to drop the dependency on CONFIG_OF, convert all device property
> getters from OF-specific to generic device properties and stop pulling
> in any linux/of.h symbols.
Is the intention to read these properties from ACPI tables?
If so, it would be nice to document these properties in
Documentation/firmware-guide/acpi/dsd.
> - if (of_property_read_bool(np, "snps,tso"))
> + if (device_property_present(dev, "snps,tso"))
> plat_dat->flags |= STMMAC_FLAG_TSO_EN;
Do you actually need this in the ACPI binding? Is there a reason not
to just hard code it enabled? You don't need to worry about backwards
compatibility here, because this is the first ACPI device.
> - if (of_device_is_compatible(np, "qcom,qcs404-ethqos"))
> + if (device_is_compatible(dev, "qcom,qcs404-ethqos"))
> plat_dat->flags |= STMMAC_FLAG_RX_CLK_RUNS_IN_LPI;
What is your target hardware? Will qcom,qcs404-ethqos every use ACPI?
Maybe this should actually stay as of_device_is_compatible, to make it
clear this is an device tree only device? There is no need to mess up
the ACPI binding with things which will never actually use ACPI.
Andrew
More information about the linux-riscv
mailing list