From patchwork Mon Jan 27 07:29:14 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Senozhatsky X-Patchwork-Id: 13951023 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 54029C0218C for ; Mon, 27 Jan 2025 07:30:00 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id D5C35280123; Mon, 27 Jan 2025 02:29:59 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id CB99F2800DA; Mon, 27 Jan 2025 02:29:59 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A5407280123; Mon, 27 Jan 2025 02:29:59 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 81E0D2800DA for ; Mon, 27 Jan 2025 02:29:59 -0500 (EST) Received: from smtpin23.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 3B82A4B236 for ; Mon, 27 Jan 2025 07:29:59 +0000 (UTC) X-FDA: 83052407718.23.1F5BD5D Received: from mail-pj1-f51.google.com (mail-pj1-f51.google.com [209.85.216.51]) by imf24.hostedemail.com (Postfix) with ESMTP id 5E3FA18000E for ; Mon, 27 Jan 2025 07:29:57 +0000 (UTC) Authentication-Results: imf24.hostedemail.com; dkim=pass header.d=chromium.org header.s=google header.b=Y++ALsrT; spf=pass (imf24.hostedemail.com: domain of senozhatsky@chromium.org designates 209.85.216.51 as permitted sender) smtp.mailfrom=senozhatsky@chromium.org; dmarc=pass (policy=none) header.from=chromium.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1737962997; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=ZMKoDSDfvoX+go24fej91nvl1Fy002IINq4VDAWYIx0=; b=RdlZdx+wCA5koYFrx2MUAgDNOFfoXLVG8sGmjRLZxzVTy8djDGDwRavz0QqEER+WyNMpJ0 1plTacOh51pmQTAoyUlHv5BcCsXYJ+7fJ8AW9p1oI91lD8XJkyKkhKRlqvengViTMLy35+ oRZoEsD4sOYpWVdQ3Dfsd2NXmOY2PtQ= ARC-Authentication-Results: i=1; imf24.hostedemail.com; dkim=pass header.d=chromium.org header.s=google header.b=Y++ALsrT; spf=pass (imf24.hostedemail.com: domain of senozhatsky@chromium.org designates 209.85.216.51 as permitted sender) smtp.mailfrom=senozhatsky@chromium.org; dmarc=pass (policy=none) header.from=chromium.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1737962997; a=rsa-sha256; cv=none; b=iquRYJro2am9VXj456mDNjF+GNN02zJy6vpQyZkafmc7P6T1Ky3iUF3mMsXgcjGhTea+xh gGbzWRo//qnGDEziz4Cp30PyixuFeNdqsbCVvhiDeZdIeheNUFN2WOa7qSyi9/bHZIo4qo Rb1sOwAqzTlP3w8il7zprN/bbjySpg4= Received: by mail-pj1-f51.google.com with SMTP id 98e67ed59e1d1-2efe25558ddso5339926a91.2 for ; Sun, 26 Jan 2025 23:29:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1737962996; x=1738567796; darn=kvack.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ZMKoDSDfvoX+go24fej91nvl1Fy002IINq4VDAWYIx0=; b=Y++ALsrTtT5Vb491cP8eos85Q2DeZOpA+/jo3PvkznG42m5Q0rLmphJBFiIJTMfEPU QLj+tLLYPzliilAuosPK6pUz+lYmvKAhu9xKETVfnT/9jxQvJ2SCh6jrfPDrr6OJmBp4 fBCura3IRn6WJCjRv8ZMnPGEQxHlhFxy073cs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1737962996; x=1738567796; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZMKoDSDfvoX+go24fej91nvl1Fy002IINq4VDAWYIx0=; b=A2ZEEDpvlCGCaVkZ2+mQ0IUn+vJDfnNPG76+jK/4MQ+gd/BHmmmmgR7YvUzklBNUCZ z2G4R1BQP9WcjAKiYxxXBDY9tWSrSsaPZxw3oVTJQsFiSICvFzD96Hh0CY3RYRrW66sT GyfX3nohvCY2ttojEpo9XbAFQANC718XJsDBEQMWiwVFCVHFmQeRMSwLqVjzE/zdHTBb 6gBlBy25hhXDya8Fd/Vn1vzSN+gouu42PqlAI0CQ+kUhn09pkU+BzMIGwoePaPEiG+Y3 4xCg/QU3IgPQ9ZiD5ulJzf/1tdNsp+JZYdjAPr6GMoArcVL8A3ZmM5EXsgDsXUMccB/C tKsQ== X-Gm-Message-State: AOJu0Yz7+ZJ92vayQL9WUXTWjf/GE/OtH0HoU2mRL4NYCfXb8KbkbORR JMxGI/iy50JLJyFyPhcYNrzANhZu92mtR9H+fV+KQhsBO76UDrXXSuYTpOYwZg== X-Gm-Gg: ASbGncspWWmS+Nkd01UP5eQbupsjp0ZwUSV+T9dk6M8YqGDXi02BB+9a6kqo9qwiIiW LvMTPnEi45UJ5RlnXk52p0QenkD6z4nprwdoBOtIRmiXs9+Ag2LbkyOiTu1Jm/9I2b9Gv38IMbY R3WFcBl8AfyJtx//mPtzAqiBLpXzjndO/GZxkYJe3qBagjkmjnAhE79ByPDNPh+VJyGLJcwJt/U HictvzMMJGcuZ8EYMsBvkGzSgBLXgnVgeOPrht80rJWASBYrCFaZh+S71R/CU0v8V4/bZaCrEYA PePO060= X-Google-Smtp-Source: AGHT+IEfwUI8auttHRk1qh7AN8+U6mvQ/O5WBUL7JmvN0YslOiw0cRVxh68/cSFEaaq3Cgj0hlneng== X-Received: by 2002:a17:90b:2803:b0:2ee:ad18:b30d with SMTP id 98e67ed59e1d1-2f782c4bd4emr8745204a91.6.1737962996210; Sun, 26 Jan 2025 23:29:56 -0800 (PST) Received: from localhost ([2401:fa00:8f:203:566d:6152:c049:8d3a]) by smtp.gmail.com with UTF8SMTPSA id 98e67ed59e1d1-2f7ffb19938sm6431742a91.45.2025.01.26.23.29.54 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 26 Jan 2025 23:29:55 -0800 (PST) From: Sergey Senozhatsky To: Andrew Morton , Minchan Kim Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Sergey Senozhatsky Subject: [PATCHv2 3/9] zram: remove crypto include Date: Mon, 27 Jan 2025 16:29:14 +0900 Message-ID: <20250127072932.1289973-4-senozhatsky@chromium.org> X-Mailer: git-send-email 2.48.1.262.g85cc9f2d1e-goog In-Reply-To: <20250127072932.1289973-1-senozhatsky@chromium.org> References: <20250127072932.1289973-1-senozhatsky@chromium.org> MIME-Version: 1.0 X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: 5E3FA18000E X-Stat-Signature: eza7z7b4peqgxr9qh4ngqf64aentnwu7 X-Rspam-User: X-HE-Tag: 1737962997-149593 X-HE-Meta: U2FsdGVkX18FKb55M8/fvZPGd0VE4FCYeX0FdzhySTTs1xDloFuL8Nw6rM3Gw6WaGkuxQy9XvWYh/TaMSaJ7Qg7kJetprbxBGvN7LgGAtVDxlOI623xwyG/NPJCBp5MROAbxbS2fPXseH5oQRMTObzJWmsPk4uxtwInyQDYyMa5KWmXO3Cc6eWrcLUZ5fV6p9uhePJrKgp0FsZ+oF6mIDYK+uYet0BWoiGlY78s7TdR2HX60XxrPPjQzQBnxH1jT0ciaMQ8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36E3gzgki+g== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Remove a leftover crypto header include. Signed-off-by: Sergey Senozhatsky --- drivers/block/zram/zcomp.c | 1 - drivers/block/zram/zram_drv.c | 4 +++- drivers/block/zram/zram_drv.h | 1 - 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/block/zram/zcomp.c b/drivers/block/zram/zcomp.c index 982c769d5831..efd5919808d9 100644 --- a/drivers/block/zram/zcomp.c +++ b/drivers/block/zram/zcomp.c @@ -7,7 +7,6 @@ #include #include #include -#include #include #include "zcomp.h" diff --git a/drivers/block/zram/zram_drv.c b/drivers/block/zram/zram_drv.c index 486068dda395..c1ecaac0b39f 100644 --- a/drivers/block/zram/zram_drv.c +++ b/drivers/block/zram/zram_drv.c @@ -43,6 +43,8 @@ static DEFINE_MUTEX(zram_index_mutex); static int zram_major; static const char *default_compressor = CONFIG_ZRAM_DEF_COMP; +#define ZRAM_MAX_ALGO_NAME_SZ 64 + /* Module params (documentation at end) */ static unsigned int num_devices = 1; /* @@ -1148,7 +1150,7 @@ static int __comp_algorithm_store(struct zram *zram, u32 prio, const char *buf) size_t sz; sz = strlen(buf); - if (sz >= CRYPTO_MAX_ALG_NAME) + if (sz >= ZRAM_MAX_ALGO_NAME_SZ) return -E2BIG; compressor = kstrdup(buf, GFP_KERNEL); diff --git a/drivers/block/zram/zram_drv.h b/drivers/block/zram/zram_drv.h index 3436ddf8ab23..045032acb22f 100644 --- a/drivers/block/zram/zram_drv.h +++ b/drivers/block/zram/zram_drv.h @@ -16,7 +16,6 @@ #define _ZRAM_DRV_H_ #include -#include #include "zcomp.h"