[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <df736add-784b-40c8-9982-ed8821a8bcb6@linux.dev>
Date: Fri, 17 Jan 2025 16:03:35 +0000
From: Vadim Fedorenko <vadim.fedorenko@...ux.dev>
To: Richard Cochran <richardcochran@...il.com>
Cc: Jiawen Wu <jiawenwu@...stnetic.com>, andrew+netdev@...n.ch,
davem@...emloft.net, edumazet@...gle.com, kuba@...nel.org,
pabeni@...hat.com, linux@...linux.org.uk, horms@...nel.org,
jacob.e.keller@...el.com, netdev@...r.kernel.org, mengyuanlou@...-swift.com
Subject: Re: [PATCH net-next v5 1/4] net: wangxun: Add support for PTP clock
On 17/01/2025 15:51, Richard Cochran wrote:
> On Fri, Jan 17, 2025 at 02:15:01PM +0000, Vadim Fedorenko wrote:
>
>> there is no way ptp_clock_register() will return NULL,
>
> Really?
>
> include/linux/ptp_clock_kernel.h:
>
> 400 static inline struct ptp_clock *ptp_clock_register(struct ptp_clock_info *info,
> 401 struct device *parent)
> 402 { return NULL; }
>
> Also, sometimes the kernelDoc comments are correct, like in this case:
>
> 304 /**
> 305 * ptp_clock_register() - register a PTP hardware clock driver
> 306 *
> 307 * @info: Structure describing the new clock.
> 308 * @parent: Pointer to the parent device of the new clock.
> 309 *
> 310 * Returns a valid pointer on success or PTR_ERR on failure. If PHC
> 311 * support is missing at the configuration level, this function
> 312 * returns NULL, and drivers are expected to gracefully handle that
> 313 * case separately.
> 314 */
>
>
> Thanks,
> Richard
Well, yes, this case is a special one. Then maybe it's better to adjust
Kconfig and Makefile to avoid it?
Powered by blists - more mailing lists