Received: by 2002:ab2:60d1:0:b0:1f7:5705:b850 with SMTP id i17csp1029549lqm; Thu, 2 May 2024 03:11:32 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXbrTqI6JapDqydo8PfslPLhCVNW3S1HPPIOe+qNYeljR6iIMcbUbHJOgy5YDTEVmMP3O7pteJWfYt8/vKO0gmt5Gj08Tc1mzn4BYaKwQ== X-Google-Smtp-Source: AGHT+IETVavZf9axI4JiLo/eXwtIrnjbJ8TCToYCIj055IvSzOGXJnZIU54y/q3ngSmLAFwhEFZT X-Received: by 2002:a17:902:d904:b0:1e7:f944:b000 with SMTP id c4-20020a170902d90400b001e7f944b000mr4978038plz.24.1714644691741; Thu, 02 May 2024 03:11:31 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714644691; cv=pass; d=google.com; s=arc-20160816; b=KPJ3+Ra/pd7CmIjkzGBA9oAviUb+htwAVyEfHt0glO9PrsXtV+G22dCViVuxCHvJbW kKwcnAGFJxGTJ0c+NceSbWwSVbtAek/S+GmoXpV60e/ydo2nHaE9y54AyLlH0mlPWtTA 83MXFnWwKZBZUtqiNdTNDBrWZPeICxLmEsQE8APdObqSXOqX9XBSZF84zeVTq3WnfumF nJvFyKm8166nJ4hX37fQa7ra6uB87Ww+ApJec4b0T4m0/nflAMsVj0lLMluLyyl3NpTt rwq14UXD4sJGzFmKTVEz6ERNdAyoHGoMcvIZgIfIY2bPRul6qKLYHQpnwvNN49GoY85q /Psw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:from :feedback-id:dkim-signature:dkim-signature; bh=koBi8a5OtpD29T0eV24Y2ij/s7j1apAbux+6IxIHaR0=; fh=RK/8vhbrhjOUA34npyS3zLQeUo4bZD/N0oEXZQW22RQ=; b=CLgn5Xm7Q/OM8Kjyyb8RuPuayskddX4C2XUZr5q8xVWIb1k/9CWla2ky0/pLOw08bt WiEPkMe2E8HbM1m22SMnIvyju9vExefTzUe0oxTf5t2aWZn6w34Fp75bghovk95HXKps 3aYU3vEZzeWrKs/tl3RTqUCWSepaIUaER6VoFD3D99EbORdiI3OqxU68VlqHKKipj7OQ v3ZaLfUk1GHZh3EXQzL/WeX0f9RUQJk0OoyH3Usl0AelcTQStESzkI0iDBbVSFSyqOdw gE2EG/W2pS8x/6jK9W1imPR3M1CkYG5nId9mSAQGu0KzqIHkQ5PWV6CAojMlr51jaNhl Sxxg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@flygoat.com header.s=fm1 header.b=ThypioNq; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=MwWsdNvK; arc=pass (i=1 spf=pass spfdomain=flygoat.com dkim=pass dkdomain=flygoat.com dkim=pass dkdomain=messagingengine.com dmarc=pass fromdomain=flygoat.com); spf=pass (google.com: domain of linux-kernel+bounces-166263-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-166263-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=flygoat.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id x11-20020a170902ea8b00b001eb1ce906b5si683804plb.291.2024.05.02.03.11.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 May 2024 03:11:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-166263-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@flygoat.com header.s=fm1 header.b=ThypioNq; dkim=pass header.i=@messagingengine.com header.s=fm3 header.b=MwWsdNvK; arc=pass (i=1 spf=pass spfdomain=flygoat.com dkim=pass dkdomain=flygoat.com dkim=pass dkdomain=messagingengine.com dmarc=pass fromdomain=flygoat.com); spf=pass (google.com: domain of linux-kernel+bounces-166263-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-166263-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=flygoat.com 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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 282DFB2273B for ; Thu, 2 May 2024 09:59:50 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7150356B7B; Thu, 2 May 2024 09:59:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=flygoat.com header.i=@flygoat.com header.b="ThypioNq"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="MwWsdNvK" Received: from fout6-smtp.messagingengine.com (fout6-smtp.messagingengine.com [103.168.172.149]) (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 8E89B44374; Thu, 2 May 2024 09:59:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=103.168.172.149 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714643980; cv=none; b=lUODh5ocmtm7R286BEEx7nFe7WvCkCkTR/aqulOb4Sxiy/ddnWP5XHUzDPlA9WUdFFFo4mrA+CgYFdeFwoCQ/cT7PhRkiQLq2ZlQC3H+Dat8DeMiflBEgB5ZrKnk0CaxNgWxCvcuxjt2kTo9cgFyS09hgK3lyNdkH4uEjO3l208= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714643980; c=relaxed/simple; bh=DcVD+OAMhzUIPuBLicTKktBmrnqdwg9u8cdk9CXSAuc=; h=From:Subject:Date:Message-Id:MIME-Version:Content-Type:To:Cc; b=fbjFJrJ35T2qKv7P5su4mrtN2+hHHtbi0DuT08QfLJ1X0Fg0aTR0fpCBsZYaiGTT5V8M2FA6hIX7E08U3zytoCdyjf659mOrfo/Tk7cbPfNgpbM78OtSN4QxB7sqwLXtlQDrVLVEPShPN+oOJcQjC+Vu3fufWKnPvptgVpglKSo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=flygoat.com; spf=pass smtp.mailfrom=flygoat.com; dkim=pass (2048-bit key) header.d=flygoat.com header.i=@flygoat.com header.b=ThypioNq; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=MwWsdNvK; arc=none smtp.client-ip=103.168.172.149 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=flygoat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flygoat.com Received: from compute7.internal (compute7.nyi.internal [10.202.2.48]) by mailfout.nyi.internal (Postfix) with ESMTP id 6132613810C2; Thu, 2 May 2024 05:59:36 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Thu, 02 May 2024 05:59:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=flygoat.com; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:message-id:mime-version:reply-to :subject:subject:to:to; s=fm1; t=1714643976; x=1714730376; bh=ko Bi8a5OtpD29T0eV24Y2ij/s7j1apAbux+6IxIHaR0=; b=ThypioNqNlMuH8fNFf N4HyccuabbnohpAri65HT93Enp+EdhGrKDjAuVDYTGBtclnullUCh7rRawDDuz4A BnZDcPPtpuuCGEaGMLK88zkS0zqn8KAmKYKl5+kPfke3GdUZlzQHRLmPPW2HWzYw RzSYLA4PINhcmrsbLKVrqqFlHbO/ASfL/PGOTx3H8muBN74I7099doAMiNcwl6CU vB2Ge/d2c7rMX1aJ41RNFLAdAzhPmgfkt0fuuR53CGx9vTflUQKJ544Kl9c/LgLx gfxy+LZCcVHT5rgOoi/DWfIVufzYgFnWetrmloRBrOQa7RhBbm4iTKIM/NRh7yUA Mebw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type: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=fm3; t=1714643976; x=1714730376; bh=koBi8a5OtpD29 T0eV24Y2ij/s7j1apAbux+6IxIHaR0=; b=MwWsdNvKNeM7xslSQoINFqem3I7RC GaIHB0maHz55oFz+eyg+EeNi2zttMQLct5x0NoSymmPOurhyuUCmpVBQ56XMGPHn AWaJByinctob/IooKGGuIOcNcOeZRMPRAygfPachOh4D9Ka06UIW5S1NKjs7QbVq R7/Q5uGg20S2trwQGe31EfIBkZjX6rg7OWkUMo7Xf4ok67gYEPBoW4M1VkQL4wpl aw1Iee70HWvpUJyhjcVJRGo5G7EOc8gOGgQxyIfRTAsuhmqFGTerQFcvKIfcpCE5 q+DEzeP1fIPBZnG6n5vVTgH1YgVd0g12kBDG71L2TK7OAnx5EcT/UqRYQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrvddukedgvdefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffufffkgggtgffvvefosehtjeertdertdejnecuhfhrohhmpeflihgrgihu nhcujggrnhhguceojhhirgiguhhnrdihrghnghesfhhlhihgohgrthdrtghomheqnecugg ftrfgrthhtvghrnhepgfevffejteegjeeflefgkeetleekhfeugfegvdeuueejkeejteek kedvfffffedunecuffhomhgrihhnpehkvghrnhgvlhdrohhrghenucevlhhushhtvghruf hiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehjihgrgihunhdrhigrnhhgsehf lhihghhorghtrdgtohhm X-ME-Proxy: Feedback-ID: ifd894703:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 2 May 2024 05:59:35 -0400 (EDT) From: Jiaxun Yang Subject: [PATCH v3 0/9] MIPS: Unify low-level debugging functionalities Date: Thu, 02 May 2024 10:59:27 +0100 Message-Id: <20240502-mips_debug_ll-v3-0-3b61f30e484c@flygoat.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-B4-Tracking: v=1; b=H4sIAP9jM2YC/32MSwqDMBQAryJZNyU+JbZd9R5FJJ8XfaCNJFYq4 t0b3XXRLmdgZmURA2Fkt2xlAWeK5J8JilPGTKeeLXKyiRkIKEUBkg80xsaifrVN33ODFTjEXEs FLDVjQEfv4/eoE3cUJx+WYz/Dbn+dZuCCV4WQFwXK2vx6d/3SejWdjR/29b9Oy1JpU0kHKv/q6 m3bPss3m/bkAAAA To: Thomas Bogendoerfer Cc: linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, Jiaxun Yang , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=2679; i=jiaxun.yang@flygoat.com; h=from:subject:message-id; bh=DcVD+OAMhzUIPuBLicTKktBmrnqdwg9u8cdk9CXSAuc=; b=owGbwMvMwCHmXMhTe71c8zDjabUkhjTjFPaHsRfPCJ1RWfr29GwrBR+TH0rrnsQyvOuoXnNAo vdidJF2RykLgxgHg6yYIkuIgFLfhsaLC64/yPoDM4eVCWQIAxenAEzkTCfD/9Dcv7NORx20VY81 548x1WfbPpUrbl/z6/a8GpckT6ViBYZfTP/TFoc6T3/ttnup4iyTpNvrxd8VP721dMExbrvHXNs amAA= X-Developer-Key: i=jiaxun.yang@flygoat.com; a=openpgp; fpr=980379BEFEBFBF477EA04EF9C111949073FC0F67 Hi all, This is a attempt to bring all low-level debugging print functions together and provide a arm-like low-level debugging interface and a further capability to debug early exceptions. This patch elimiate platform specific early_printk, zboot printing functions and cps-vec-ns16550 by newly introduced debug_ll. Hope you'll find them handy :-) Happy hacking! Thanks Signed-off-by: Jiaxun Yang --- Changes in v3: - Collect review tags - Fix an indentation - Link to v2: https://lore.kernel.org/r/20240326-mips_debug_ll-v2-0-b64abc76f2a1@flygoat.com --- Jiaxun Yang (9): MIPS: asm: Move strings to .rodata.str section MIPS: debug: Implement low-level debugging functions MIPS: debug: Hook up DEBUG_LL with early printk MIPS: debug: Provide an early exception vector for low-level debugging MIPS: debug_ll: Add Kconfig symbols for some 8250 uarts MIPS: debug_ll: Implement support for Alchemy uarts MIPS: debug_ll: Implement support for AR933X uarts MIPS: zboot: Convert to use debug_ll facilities MIPS: CPS: Convert to use debug_ll facilities arch/mips/Kconfig | 12 +- arch/mips/Kconfig.debug | 240 +++++++++++++++++++++++-------- arch/mips/boot/compressed/Makefile | 9 +- arch/mips/boot/compressed/dbg.c | 39 ----- arch/mips/boot/compressed/debug-vec.S | 3 + arch/mips/boot/compressed/debug.S | 3 + arch/mips/boot/compressed/decompress.h | 8 +- arch/mips/boot/compressed/head.S | 6 + arch/mips/boot/compressed/uart-16550.c | 49 ------- arch/mips/boot/compressed/uart-alchemy.c | 9 -- arch/mips/boot/compressed/uart-ath79.c | 2 - arch/mips/boot/compressed/uart-prom.c | 9 -- arch/mips/include/asm/asm.h | 2 +- arch/mips/include/debug/8250.S | 60 ++++++++ arch/mips/include/debug/alchemy.S | 46 ++++++ arch/mips/include/debug/ar933x.S | 41 ++++++ arch/mips/include/debug/uhi.S | 48 +++++++ arch/mips/kernel/Makefile | 4 +- arch/mips/kernel/cps-vec.S | 16 +-- arch/mips/kernel/debug-vec.S | 194 +++++++++++++++++++++++++ arch/mips/kernel/debug.S | 130 +++++++++++++++++ arch/mips/kernel/early_printk.c | 19 +++ arch/mips/kernel/head.S | 4 + 23 files changed, 756 insertions(+), 197 deletions(-) --- base-commit: 084c8e315db34b59d38d06e684b1a0dd07d30287 change-id: 20240326-mips_debug_ll-ce72fee1b6a2 Best regards, -- Jiaxun Yang