# Re: \[PATCH v3 5/8\] ptp/kvm, arm\_arch\_timer: Set system\_counterval\_t.cs\_id to constant

- From: Peter Hilber \<hidden\>
- Date: 2024-02-01 14:04:48 
- List: netdev
- Page: https://ratatoskr.run/netdev/2024/02/2480654
- Thread: https://ratatoskr.run/linux-arm-kernel/2024/02/2479892/t.md

```text
On 01.02.24 14:52, Marc Zyngier wrote:
> On Thu, 01 Feb 2024 01:04:50 +0000,
> Peter Hilber [ref] wrote:
>>
>> Identify the clocksources used by ptp_kvm by setting clocksource ID enum
>> constants. This avoids dereferencing struct clocksource. Once the
>> system_counterval_t.cs member will be removed, this will also avoid the
>> need to obtain clocksource pointers from kvm_arch_ptp_get_crosststamp().
>>
>> The clocksource IDs are associated to timestamps requested from the KVM
>> hypervisor, so the proper clocksource ID is known at the ptp_kvm request
>> site.
>>
>> While at it, also rectify the ptp_kvm_get_time_fn() ret type.
> 
> Not sure what is wrong with that return type, but this patch doesn't
> seem to affect it.
> 

I meant to refer to the type of the variable ret declared in
ptp_kvm_get_time_fn(). I will reword the commit message to make this clear.

Thanks for the comment,

Peter
```
