From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0FBEE3AEF23; Fri, 29 May 2026 20:01:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780084885; cv=none; b=YouBvVMbI8mHYSkF3fIOawgdxL6nUXFtlnqxsszGpSfKdoxXTTQgJpi8CQZU7WRev/iy5hNHPRk8LOUaQn2LoGx94oyGrsSzoC2nfm0M1DoSrEcnRAQkEeomUFZG3/zfscjIEWaDXlr/DsAlV5vmiYeqvblcRnDlXmxNgP7xlqo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780084885; c=relaxed/simple; bh=2T5s2PrZIU2o4Dm+5AlC+bvg7KAyKf6ZQhZYdGRS71g=; h=Date:Message-ID:From:To:Cc:Subject:References:MIME-Version: Content-Type; b=oMoZB+h8ZIHcKZg4zU0/nikyO0fu2BfP5lNhpLb+l7LERBotB+DWzdZXXCfgfYMIAkh4MXKpuaRxs+2mDD7xlPLdZMY0j8gQO3YE1HQAYpEPhsrSXt5OuEz/du95hdRvW+FccCtmoLcBvFThW4rVOudqIRnuNrGsjoO91dEGmoA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Bt/68hw5; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Bt/68hw5" Received: by smtp.kernel.org (Postfix) with ESMTPSA id F14791F00893; Fri, 29 May 2026 20:01:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1780084883; bh=d8ecuHgn3EbMBTOWdGcfN7Rpmd+nK58rNN4GVOEm3A4=; h=Date:From:To:Cc:Subject:References; b=Bt/68hw5SylVR4cQs+fhfp1c9Axf+EESnpGCcBzgg+/1sIu4X+mDmaAFcXjpqkUqt Q42CfZ/POXdHvk+o8Jtv/I/N4jiii84+6J+r18Quc/J1BNeLwJQSWV6PFCRrgHdeJC oPN1ZXwNpomrEYLZgT7g/KLCDZhJmrd7IIDE3gipNMFXn4RDeFCeJbmt1r9en3j2FC B8aaU0aHvp4LEjYPq1PD5xgeVZWBvxPYnambbtVLK00TNK8twaCfQNGNhbzGRJc114 oUsEJf8GVOWtDnU9UP1iM8oOP2JOxloF3ACfu7jG5tmWVfeUcYBlBblqSUxdU5r1tQ sPgA6cDimISoQ== Date: Fri, 29 May 2026 22:01:21 +0200 Message-ID: <20260529195558.097464513@kernel.org> User-Agent: quilt/0.69 From: Thomas Gleixner To: LKML Cc: David Woodhouse , Miroslav Lichvar , John Stultz , Stephen Boyd , Anna-Maria Behnsen , Frederic Weisbecker , thomas.weissschuh@linutronix.de, Arthur Kiyanovski , Rodolfo Giometti , Vincent Donnefort , Marc Zyngier , Oliver Upton , kvmarm@lists.linux.dev, Oliver Upton , Richard Cochran , netdev@vger.kernel.org, Takashi Iwai , Miri Korenblit , Johannes Berg , Jacob Keller , Tony Nguyen , Saeed Mahameed , Peter Hilber , "Michael S. Tsirkin" , virtualization@lists.linux.dev, linux-wireless@vger.kernel.org, linux-sound@vger.kernel.org, David Woodhouse , Vadim Fedorenko Subject: [patch V2 23/25] timekeeping: Add support for AUX clock cross timestamping References: <20260529193435.921555544@kernel.org> Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 From: Thomas Gleixner Now that all prerequisites are in place add the final support for AUX clocks in get_device_system_crosststamp(), which enables the PTP layer to support hardware cross timestamps with a new IOTCL. Signed-off-by: Thomas Gleixner Tested-by: Arthur Kiyanovski Reviewed-by: David Woodhouse Reviewed-by: Thomas Weißschuh Reviewed-by: Jacob Keller --- kernel/time/timekeeping.c | 6 ++++++ 1 file changed, 6 insertions(+) --- a/kernel/time/timekeeping.c +++ b/kernel/time/timekeeping.c @@ -1517,6 +1517,12 @@ int get_device_system_crosststamp(int (* tkd = &tk_core; offs = &tk_core.timekeeper.offs_real; break; + case CLOCK_AUX ... CLOCK_AUX_LAST: + tkd = aux_get_tk_data(xtstamp->clock_id); + if (!tkd) + return -ENODEV; + offs = &tkd->timekeeper.offs_aux; + break; default: WARN_ON_ONCE(1); return -ENODEV;