From patchwork Wed Jun 21 10:16:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiri Slaby X-Patchwork-Id: 694862 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DA17BEB64DD for ; Wed, 21 Jun 2023 10:16:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231736AbjFUKQh (ORCPT ); Wed, 21 Jun 2023 06:16:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37066 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231313AbjFUKQe (ORCPT ); Wed, 21 Jun 2023 06:16:34 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 04C0610FF; Wed, 21 Jun 2023 03:16:25 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 78E57614FB; Wed, 21 Jun 2023 10:16:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C9E68C433CA; Wed, 21 Jun 2023 10:16:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1687342583; bh=hjwp7ItGmHIggbX9Pd6LvtVbXVqDEOR8otZ+Y4JaTu0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uNvkdiF4FusRU1x/rqIMyQ2ujF5y1MPWfSO9o0oEqlpV0XUXUd37+A9SraY/aNTFr UOsxhdWmZuFgvnpDmWEEtW3IiMSzN906hBDGtvwYfQJk9CBG+Px7x1F97Sk0WDKAEp IKCfdLkf9BWKD4QlK5rIJf+0dsrApspERH7kXbeJ0ng4U/e5oBSR3EByiGZ406B53c ac0+whiE4mwjcHuUVqrolEX4d+RTaUqC8JL8qmcunl+hfMX3W8M5r0DKvBEbdmrI8P yGnKKTbEeMx+2aVTKCkVHleHi6xrw1eidMXnsV4Cda+hNE80MBvATXhgR5cyjKisr+ seiJ0y1csL0CA== From: "Jiri Slaby (SUSE)" To: gregkh@linuxfoundation.org Cc: linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org, "Jiri Slaby (SUSE)" Subject: [PATCH 6/6] tty_audit: make data of tty_audit_log() const Date: Wed, 21 Jun 2023 12:16:11 +0200 Message-ID: <20230621101611.10580-7-jirislaby@kernel.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230621101611.10580-1-jirislaby@kernel.org> References: <20230621101611.10580-1-jirislaby@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-serial@vger.kernel.org 'data' are only read (passed down to audit_log_n_hex()), so they can be const -- the same what is expected in audit_log_n_hex(). Only a minor cleanup to be consistent. Signed-off-by: Jiri Slaby (SUSE) --- drivers/tty/tty_audit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/tty/tty_audit.c b/drivers/tty/tty_audit.c index 5cbe28ac1763..24d010589379 100644 --- a/drivers/tty/tty_audit.c +++ b/drivers/tty/tty_audit.c @@ -59,7 +59,7 @@ static void tty_audit_buf_free(struct tty_audit_buf *buf) } static void tty_audit_log(const char *description, dev_t dev, - unsigned char *data, size_t size) + const unsigned char *data, size_t size) { struct audit_buffer *ab; pid_t pid = task_pid_nr(current);