lkml.org 
[lkml]   [2021]   [Nov]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v11 2/2] drivers/perf: hisi: Add driver for HiSilicon PCIe PMU
From
Date


On 2021/11/18 6:41, Krzysztof Wilczyński wrote:
> Hi Qi,
>
> Thank you for working on this! Looks really good!
>
> Below a few tiny nitpicks that you are more than welcome to ignore, of
> course, as these would have little weight on the final product, so to
> speak.
>
>> +struct hisi_pcie_pmu {
>> + struct perf_event *hw_events[HISI_PCIE_MAX_COUNTERS];
>> + struct hlist_node node;
>> + struct pci_dev *pdev;
>> + struct pmu pmu;
>> + void __iomem *base;
>> + int irq;
>> + u32 identifier;
>> + /* Minimum and maximum bdf of root ports monitored by PMU */
>> + u16 bdf_min;
>> + u16 bdf_max;
>> + int on_cpu;
>> +};
>
> Would the above "bdf" be the PCI addressing schema? If so, then we could
> capitalise the acronym to keep it consistent with how it's often referred
> to in the PCI world.
>
Hi Krzysztof,

got it, will change it to Bdf to keep the consistent, thanks.

> [...]
>> +static int __init hisi_pcie_module_init(void)
>> +{
>> + int ret;
>> +
>> + ret = cpuhp_setup_state_multi(CPUHP_AP_PERF_ARM_HISI_PCIE_PMU_ONLINE,
>> + "AP_PERF_ARM_HISI_PCIE_PMU_ONLINE",
>> + hisi_pcie_pmu_online_cpu,
>> + hisi_pcie_pmu_offline_cpu);
>> + if (ret) {
>> + pr_err("Failed to setup PCIe PMU hotplug, ret = %d.\n", ret);
>> + return ret;
>> + }
>
> The above error message could be made to be a little more aligned in terms
> of format with the other messages, thus it would be as follows:
>
> pr_err("Failed to setup PCIe PMU hotplug: %d.\n", ret);
>
> Interestingly, there would be then no need to add the final dot (period) at
> the end here, and that would be true everywhere else.
>

thanks for your reminder , I'll fix that printout message to keep align.

Thanks,
Qi


> Again, thank you so much for working on this, it's very much appreciated!
>
> Acked-by: Krzysztof Wilczyński <kw@linux.com>
>
> Krzysztof
> .
>

\
 
 \ /
  Last update: 2021-11-18 14:11    [W:0.225 / U:0.280 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site