Received: by 2002:ab2:6309:0:b0:1fb:d597:ff75 with SMTP id s9csp47408lqt; Wed, 5 Jun 2024 16:52:11 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWbqa4em3oIApgKQZoDqGf9Kbz+e2dqAAzsjXOKs1YrR9N1VEyz8HvShz56YcIDnaHqSQV7R3tb5oB/nzX94pBx8n8xRm7JvRjl0QWT8g== X-Google-Smtp-Source: AGHT+IExba1aycHCoXvaaLZAqmXgsCCzWhaSOw1nyLxn3YF6fOpiy8Cy3zrtPy0utUm/4zP8GnP6 X-Received: by 2002:a05:690c:244:b0:618:96eb:980d with SMTP id 00721157ae682-62cbb4b1efdmr44396127b3.1.1717631530793; Wed, 05 Jun 2024 16:52:10 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717631530; cv=pass; d=google.com; s=arc-20160816; b=gBYxlOXir9V4JZj9vVv6MLXrgK79H92glGA4qdLhrGChBLVjBQz46M0sTE8EC8N2Hd X0xMxR3fy1qd7cAcEkxrp4JF+jYbr3Sq+EL7PdzpzeeuLAwISGFr7vj8kIWwMPq15ukJ cqZB0w5M8/dpuIPEtN8qjYcFpdDhZpx1yx1PqFpMov+pHNleC6rce2e9d3kNyh8KGjbD H9qyRwan5ee5IHhifqHpLs6SNS2dY8XFzUboeZZrM/VzyKcm1K5GvtrTGLQCtHTwsrL6 SyKszrHu9ZVqaR2rm7E1Wa23odGefksGqYJW5prm4vIS4c5zIS+B9leyk66g914CR7gA xxZA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:feedback-id:dkim-signature:dkim-signature; bh=Fiy9hqDbM4Tn7rMtDl155r1TRdgLzNnb58yHVTsN+CE=; fh=5EQyDiYgg+kua2A2AF9eJME8jasrrRA/Pgg86y+lzvY=; b=E6gTcP2JpwFqDD5SFj5hjxTQ82cuR8JVRC0fvDayjzbjMZxLrEACAqLndBrUAAVqUx hw6RPqJFuTqm0X717DemqTCcnn5LsNt51y/S0lKg7++7fFif8O3lIFDoa7Ml86jx0B+j c4Rv5JRW46D/s5potQOTJj3Vq1nH98f4jwEztwIhjEZ6iN4hdzq4Dfo3ccnCDAkUfxSo zeEJBmLeEHWWjIBoUDBqdbmSrnd+2VzLSdRnwIUxnqyvUSa34Rr0tLz3PUy97H8/sWAa F9ufgYd9+JfmjGHfPuF3elZtkl2x8BszrTMHo44YuGM85FeDHGcNT51tkLj9JFNf8MZz VL2Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@sakamocchi.jp header.s=fm1 header.b=dCkjvKZ+; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=plSjkLye; arc=pass (i=1 spf=pass spfdomain=sakamocchi.jp dkim=pass dkdomain=sakamocchi.jp dkim=pass dkdomain=messagingengine.com dmarc=pass fromdomain=sakamocchi.jp); spf=pass (google.com: domain of linux-kernel+bounces-203421-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-203421-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sakamocchi.jp Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id 6a1803df08f44-6b04f685409si2213926d6.149.2024.06.05.16.52.10 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 05 Jun 2024 16:52:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-203421-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@sakamocchi.jp header.s=fm1 header.b=dCkjvKZ+; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=plSjkLye; arc=pass (i=1 spf=pass spfdomain=sakamocchi.jp dkim=pass dkdomain=sakamocchi.jp dkim=pass dkdomain=messagingengine.com dmarc=pass fromdomain=sakamocchi.jp); spf=pass (google.com: domain of linux-kernel+bounces-203421-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-203421-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sakamocchi.jp Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 77D831C23061 for ; Wed, 5 Jun 2024 23:52:10 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 665DD168C0C; Wed, 5 Jun 2024 23:52:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=sakamocchi.jp header.i=@sakamocchi.jp header.b="dCkjvKZ+"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="plSjkLye" Received: from wfhigh5-smtp.messagingengine.com (wfhigh5-smtp.messagingengine.com [64.147.123.156]) (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 B42EB1AAA5 for ; Wed, 5 Jun 2024 23:52:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=64.147.123.156 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717631524; cv=none; b=AB2R3MAbLlRQ2DUoGwEMBYXfNFtqBQQL/UdYNX7zZkZvzmM2Y4mMiwBC6i6RaaDhnYLNk4h1e75CxulN/Xq8w7aD4fBFk9isBvrU2XK3pQeg0VdTmmoUp6SGyk0X7GJC/qyQ9n/5+ZNfTt18r3Nd8qCdTmU3QfqGYD/wfCn5lcM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717631524; c=relaxed/simple; bh=UAHBzCNBzgQHC5AkOhgB0xfu06l9LyKNv/ykFdJYCVw=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=j6gOxTINLgWS4ZcmQe2BBqKT+cGP1KbmBrpJks6jK/0cWUxHDayVRNpD7DtbxTdtDot+dwVAw7hYMxN+KpvTdFBTbGVrsK6Fkb8IxP7sqIrQAwLhB3zaSzZb0AUN3wYMbd++tntYXj3WptkSZoEDhfaXkwrvvP17bQUr0GRA2i8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=sakamocchi.jp; spf=pass smtp.mailfrom=sakamocchi.jp; dkim=pass (2048-bit key) header.d=sakamocchi.jp header.i=@sakamocchi.jp header.b=dCkjvKZ+; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=plSjkLye; arc=none smtp.client-ip=64.147.123.156 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=sakamocchi.jp Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sakamocchi.jp Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailfhigh.west.internal (Postfix) with ESMTP id C966F18000BC; Wed, 5 Jun 2024 19:52:00 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Wed, 05 Jun 2024 19:52:00 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sakamocchi.jp; h=cc:cc:content-transfer-encoding:content-type:date:date:from :from:in-reply-to:message-id:mime-version:reply-to:subject :subject:to:to; s=fm1; t=1717631520; x=1717717920; bh=Fiy9hqDbM4 Tn7rMtDl155r1TRdgLzNnb58yHVTsN+CE=; b=dCkjvKZ+1Z6m6JkV2utfIVRELm Qh7ZgCXO/1TVNwrwhe+z0NhyKWxeTmwUD8ELvXGUbWgHGGP5AhjDhmTZLO9AW/hj DNWqdBwcM2nS+N19y1dYOaL/FK/NEtnQX8BAZFrAJWZInhbsRmeyrpPexBPOT4lf YajDs+cP1U8RxA5B6yv0zASOQOlK3g7T84CEkqhOKJsiF0ftMedEGZOfZ37aBQ0H /sgondso1ib5LNaBjpm/TE87xXqWNcSZHdoSGwdiwVp61HAodvgrFbXAmAeIW5JA F2W38sRAL99GGAV9qQve0wHdlda1QEojQ9IpP3lUmBLTFSNv7EL9uYxYVkxg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:message-id:mime-version:reply-to:subject:subject:to :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; t=1717631520; x=1717717920; bh=Fiy9hqDbM4Tn7rMtDl155r1TRdgL zNnb58yHVTsN+CE=; b=plSjkLyeM01TFD+QNsQPWHogM1Y44wUqWCLxabwfgOVq 1vycik6jUDG8MO/TdPE6zAxtGwc4lH4w6sw6DyqXgY/7ChTEQbowMavDxHRg0rU2 1O2igghBO/BL1p5l2Psl7CAiPCVg7i/eygwZrAg7z8RgU43BA4PNPwYsbSbiVMr7 tZEJo4g8WnoB/ipIPuFFZSTwYNTRsTTGrrkLJjsLPaRnPTApI9WdhLcVIpGtRv+P i/lzXacKhS/4XkDSvFWneF/Se9sDiUKH8yxcNpmO2UoYnd6ksUKlnLnhx1k8kJ9M GdOAYYQr2FGfNHtqgM3QrTf16gBR5kZIcRMwxtL2rw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrvdeljedgvdeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefhvfevufffkffoggfgsedtkeertd ertddtnecuhfhrohhmpefvrghkrghshhhiucfurghkrghmohhtohcuoehoqdhtrghkrghs hhhisehsrghkrghmohgttghhihdrjhhpqeenucggtffrrghtthgvrhhnpeffvdeuleffve ekudfhteejudffgefhtedtgfeutdfgvdfgueefudehveehveekkeenucevlhhushhtvghr ufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehoqdhtrghkrghshhhisehsrg hkrghmohgttghhihdrjhhp X-ME-Proxy: Feedback-ID: ie8e14432:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 5 Jun 2024 19:51:59 -0400 (EDT) From: Takashi Sakamoto To: linux1394-devel@lists.sourceforge.net Cc: linux-kernel@vger.kernel.org Subject: [PATCH 00/11] firewire: add tracepoints events for self ID sequence Date: Thu, 6 Jun 2024 08:51:44 +0900 Message-ID: <20240605235155.116468-1-o-takashi@sakamocchi.jp> X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Hi, In core function, the enumeration of self ID sequences is the first step to build bus topology for the current generation. Currently, 1394 OHCI driver has a module option to dump the content of self ID sequence, while it is implemented by printk. My recent work is going to replace such logging with tracepoints events, and this series of changes is for the self ID sequence. The content of self ID sequence is delivered by a kind of phy packet, and its serialization and deserialization codes exist in both core function and 1394 OHCI driver. They include some redundancies, and the series of changes includes some inline helper functions to replace them. In the series of changes, some KUnit tests are added to check behaviour of the enumeration and the helper functions. Takashi Sakamoto (11): firewire: core: add enumerator of self ID sequences and its KUnit test firewire: core: add helper function to handle port status from self ID sequence and its KUnit test firewire: core: minor code refactoring for topology builder firewire: ohci: minor code refactoring for self ID logging firewire: core: use helper functions for self ID sequence firewire: ohci: use helper functions for self ID sequence firewire: core: add common inline functions to serialize/deserialize self ID packet firewire: core: use helper inline functions to deserialize self ID packet firewire: ohci: use helper inline functions to serialize/deserialize self ID packet firewire: core: arrangement header inclusion for tracepoints events firewire: core: add tracepoints event for self_id_sequence drivers/firewire/.kunitconfig | 1 + drivers/firewire/Kconfig | 15 ++ drivers/firewire/Makefile | 1 + drivers/firewire/core-topology.c | 219 ++++++--------- drivers/firewire/core-trace.c | 18 ++ drivers/firewire/core-transaction.c | 2 +- drivers/firewire/ohci.c | 148 ++++++---- drivers/firewire/packet-header-definitions.h | 2 + drivers/firewire/packet-serdes-test.c | 255 ++++++++++++++++++ drivers/firewire/phy-packet-definitions.h | 247 +++++++++++++++++ .../firewire/self-id-sequence-helper-test.c | 152 +++++++++++ include/trace/events/firewire.h | 61 ++++- 12 files changed, 935 insertions(+), 186 deletions(-) create mode 100644 drivers/firewire/phy-packet-definitions.h create mode 100644 drivers/firewire/self-id-sequence-helper-test.c -- 2.43.0