Message ID | 20230330091309.16215-3-shubhrajyoti.datta@amd.com (mailing list archive) |
---|---|
State | Changes Requested, archived |
Headers | show |
Series | clk: zynqmp: Add versal-net compatible string | expand |
On 30/03/2023 11:13, Shubhrajyoti Datta wrote: > From: Jay Buddhabhatti <jay.buddhabhatti@xilinx.com> > > Add compatible string for versal-net. > > Signed-off-by: Jay Buddhabhatti <jay.buddhabhatti@xilinx.com> > Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@amd.com> > --- > > drivers/clk/zynqmp/clkc.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/clk/zynqmp/clkc.c b/drivers/clk/zynqmp/clkc.c > index 5636ff1ce552..1ea5fba20d91 100644 > --- a/drivers/clk/zynqmp/clkc.c > +++ b/drivers/clk/zynqmp/clkc.c > @@ -789,6 +789,7 @@ static int zynqmp_clock_probe(struct platform_device *pdev) > static const struct of_device_id zynqmp_clock_of_match[] = { > {.compatible = "xlnx,zynqmp-clk"}, > {.compatible = "xlnx,versal-clk"}, > + {.compatible = "xlnx,versal-net-clk"}, Why no driver data? Why do you create new driver matchings if devices are compatible? Best regards, Krzysztof
On 3/30/23 13:08, Krzysztof Kozlowski wrote: > On 30/03/2023 11:13, Shubhrajyoti Datta wrote: >> From: Jay Buddhabhatti <jay.buddhabhatti@xilinx.com> >> >> Add compatible string for versal-net. >> >> Signed-off-by: Jay Buddhabhatti <jay.buddhabhatti@xilinx.com> >> Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@amd.com> >> --- >> >> drivers/clk/zynqmp/clkc.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/drivers/clk/zynqmp/clkc.c b/drivers/clk/zynqmp/clkc.c >> index 5636ff1ce552..1ea5fba20d91 100644 >> --- a/drivers/clk/zynqmp/clkc.c >> +++ b/drivers/clk/zynqmp/clkc.c >> @@ -789,6 +789,7 @@ static int zynqmp_clock_probe(struct platform_device *pdev) >> static const struct of_device_id zynqmp_clock_of_match[] = { >> {.compatible = "xlnx,zynqmp-clk"}, >> {.compatible = "xlnx,versal-clk"}, >> + {.compatible = "xlnx,versal-net-clk"}, > > Why no driver data? Why do you create new driver matchings if devices > are compatible? It is the same discussion as we had recently in connection to emmc. versal-net is new SOC and if any issue happens we would apply workaround based on DT compatible string. And by using special compatible string directly from beginning will allow us to do changes without change DT. We actually don't need to update the driver for this. We can just simply list new dt binding and use both compatible string in DT like this. "xlnx,versal-net-clk", "xlnx,versal-clk" Thanks, Michal
On 30/03/2023 14:00, Michal Simek wrote: > > > On 3/30/23 13:08, Krzysztof Kozlowski wrote: >> On 30/03/2023 11:13, Shubhrajyoti Datta wrote: >>> From: Jay Buddhabhatti <jay.buddhabhatti@xilinx.com> >>> >>> Add compatible string for versal-net. >>> >>> Signed-off-by: Jay Buddhabhatti <jay.buddhabhatti@xilinx.com> >>> Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@amd.com> >>> --- >>> >>> drivers/clk/zynqmp/clkc.c | 1 + >>> 1 file changed, 1 insertion(+) >>> >>> diff --git a/drivers/clk/zynqmp/clkc.c b/drivers/clk/zynqmp/clkc.c >>> index 5636ff1ce552..1ea5fba20d91 100644 >>> --- a/drivers/clk/zynqmp/clkc.c >>> +++ b/drivers/clk/zynqmp/clkc.c >>> @@ -789,6 +789,7 @@ static int zynqmp_clock_probe(struct platform_device *pdev) >>> static const struct of_device_id zynqmp_clock_of_match[] = { >>> {.compatible = "xlnx,zynqmp-clk"}, >>> {.compatible = "xlnx,versal-clk"}, >>> + {.compatible = "xlnx,versal-net-clk"}, >> >> Why no driver data? Why do you create new driver matchings if devices >> are compatible? > > It is the same discussion as we had recently in connection to emmc. > versal-net is new SOC and if any issue happens we would apply workaround based > on DT compatible string. And by using special compatible string directly from > beginning will allow us to do changes without change DT. None of these arguments require growing match data. My comment was not about bindings. My comment was why do you need to grow of_device_id needlessly? > > We actually don't need to update the driver for this. We can just simply list > new dt binding and use both compatible string in DT like this. > "xlnx,versal-net-clk", "xlnx,versal-clk" Best regards, Krzysztof
On 3/30/23 15:32, Krzysztof Kozlowski wrote: > On 30/03/2023 14:00, Michal Simek wrote: >> >> >> On 3/30/23 13:08, Krzysztof Kozlowski wrote: >>> On 30/03/2023 11:13, Shubhrajyoti Datta wrote: >>>> From: Jay Buddhabhatti <jay.buddhabhatti@xilinx.com> >>>> >>>> Add compatible string for versal-net. >>>> >>>> Signed-off-by: Jay Buddhabhatti <jay.buddhabhatti@xilinx.com> >>>> Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@amd.com> >>>> --- >>>> >>>> drivers/clk/zynqmp/clkc.c | 1 + >>>> 1 file changed, 1 insertion(+) >>>> >>>> diff --git a/drivers/clk/zynqmp/clkc.c b/drivers/clk/zynqmp/clkc.c >>>> index 5636ff1ce552..1ea5fba20d91 100644 >>>> --- a/drivers/clk/zynqmp/clkc.c >>>> +++ b/drivers/clk/zynqmp/clkc.c >>>> @@ -789,6 +789,7 @@ static int zynqmp_clock_probe(struct platform_device *pdev) >>>> static const struct of_device_id zynqmp_clock_of_match[] = { >>>> {.compatible = "xlnx,zynqmp-clk"}, >>>> {.compatible = "xlnx,versal-clk"}, >>>> + {.compatible = "xlnx,versal-net-clk"}, >>> >>> Why no driver data? Why do you create new driver matchings if devices >>> are compatible? >> >> It is the same discussion as we had recently in connection to emmc. >> versal-net is new SOC and if any issue happens we would apply workaround based >> on DT compatible string. And by using special compatible string directly from >> beginning will allow us to do changes without change DT. > > None of these arguments require growing match data. My comment was not > about bindings. My comment was why do you need to grow of_device_id > needlessly? Right. Shubhrajyoti: Please update only dt binding and for versal-net we will use new compatible string followed by old one. Thanks, Michal
diff --git a/drivers/clk/zynqmp/clkc.c b/drivers/clk/zynqmp/clkc.c index 5636ff1ce552..1ea5fba20d91 100644 --- a/drivers/clk/zynqmp/clkc.c +++ b/drivers/clk/zynqmp/clkc.c @@ -789,6 +789,7 @@ static int zynqmp_clock_probe(struct platform_device *pdev) static const struct of_device_id zynqmp_clock_of_match[] = { {.compatible = "xlnx,zynqmp-clk"}, {.compatible = "xlnx,versal-clk"}, + {.compatible = "xlnx,versal-net-clk"}, {}, }; MODULE_DEVICE_TABLE(of, zynqmp_clock_of_match);