From patchwork Thu Jan 30 11:10:48 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Senozhatsky X-Patchwork-Id: 13954492 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 A01B3C0218A for ; Thu, 30 Jan 2025 11:13:06 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 28FAF2800D6; Thu, 30 Jan 2025 06:13:06 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 2158F2800D0; Thu, 30 Jan 2025 06:13:06 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 042592800D6; Thu, 30 Jan 2025 06:13:05 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id D33B42800D0 for ; Thu, 30 Jan 2025 06:13:05 -0500 (EST) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id C1A9FC0D14 for ; Thu, 30 Jan 2025 11:11:30 +0000 (UTC) X-FDA: 83063852340.05.866F3F9 Received: from mail-pl1-f169.google.com (mail-pl1-f169.google.com [209.85.214.169]) by imf10.hostedemail.com (Postfix) with ESMTP id D56ABC000D for ; Thu, 30 Jan 2025 11:11:28 +0000 (UTC) Authentication-Results: imf10.hostedemail.com; dkim=pass header.d=chromium.org header.s=google header.b=FvP2UtAl; spf=pass (imf10.hostedemail.com: domain of senozhatsky@chromium.org designates 209.85.214.169 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=1738235488; 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=Ti4+lyxlKNsrQ+jB6ZeK4CLAAqx7hgqRlGDCYQ/kK7M=; b=uPumfus05yGfkC8q4r2f/5CO3Z3YezQo5GxGX99CtIP+pCe15/btl8DW3oBc8E22qjdsrc Ute3jbV5HHTxddfASJ1GKJNJxf0VyalvrFlHZHbyDtnDhkf4GLb3YXGfAh+7T6fg3s87L0 ra7kKeUFrPRm78P1vWbdOiDO9B6eNsA= ARC-Authentication-Results: i=1; imf10.hostedemail.com; dkim=pass header.d=chromium.org header.s=google header.b=FvP2UtAl; spf=pass (imf10.hostedemail.com: domain of senozhatsky@chromium.org designates 209.85.214.169 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=1738235488; a=rsa-sha256; cv=none; b=0JEF4atvfTW/IlalB2P7WQD4dr/CBB+oINP3j3EqMpYd+J/xYvxi15Rb2EUEoB9C2NME+n Lqdz1s4x3tMXZMsSRJKJZ9L473G6IQ4cp17/BaIbBJpEzYA2B9w+RDV/PhIrdPxf0uOeMv IiArvmBUxwORmoGRHs2vYf/gWbchmlE= Received: by mail-pl1-f169.google.com with SMTP id d9443c01a7336-21654fdd5daso9564355ad.1 for ; Thu, 30 Jan 2025 03:11:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1738235487; x=1738840287; 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=Ti4+lyxlKNsrQ+jB6ZeK4CLAAqx7hgqRlGDCYQ/kK7M=; b=FvP2UtAlXWWbS4a2LAZ0o0LmpmmKsWPrpHaiju72lW4jkM22HZjfGuaZiuBOH3ipib TsUN2t1coo358pRSNpEzlwlgopPfP79qIdiqUiWKHsjLTSVTZ0V3tfx7IKDwFEbGKEBm h1xguMdaUUa53SCWKcMqXbVCNjnUOB/4jP5L4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1738235487; x=1738840287; 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=Ti4+lyxlKNsrQ+jB6ZeK4CLAAqx7hgqRlGDCYQ/kK7M=; b=Sc2cY/0nwpKb+3rAJj2j1rNqchp4G/qF9hZiwmGcLAmmARbmg75xn08E5GwAMi6PuE ZVaL3NkK+ujPC+Dq5wyzvTrv1fA47MRACxbPAjjPttrSlfIg+E660bZyTgl5WoKJ/IO2 +BWjrXxXwV0Qh+PnyvsMszEWe1bdazGgg4n58O/J85q4ZZRrVZAwyWn0tzI5ir0oLyg4 zTUQD0KXXXcGOb5rfWV7hgYj38EQvb+s7cmw86h4oyy/t+rK0mfWigT06MdXpAfMUYUS KH/96vRdbZjt8L53RmEHcp+IW1FNpPTdPy1Jy45yZNaEbJ8LJtd4gP6Vc6SuMshGuxLw fi+w== X-Forwarded-Encrypted: i=1; AJvYcCXfZMNK67R0YprY9pWQFroOKWwS5+7oFSQHKGWncBpCxjUu1gkpVCyQjkInsIu08yKuNcJHmRfsQg==@kvack.org X-Gm-Message-State: AOJu0YzTCuXf1NnvzJY7+Y/XD372FKgED8Aoes1TWnWFn87xEEPP+g3s SWjdIyOAH/QdqGNuHr7eBm+oPkBmz1Tv0etctiJFq1csDB/kYZWO41pVVz2j6Q== X-Gm-Gg: ASbGncveyM9SecIntVCOJrCHWG4n63pxyQzstZl0+SzStGyqot6nenHpnvrRwHh2Yvs 7MGSXtda0a2xHfZWMQTgOzYWsnpEqWAbUPTz1Gt3CGAzROyxEgKoHFxMEwo7WLi7iJ7zTQpgJ6I vrkSeknS7APwH3HPDCX1f8r9oJmVSkmazmaq733K5eHXE9fz8jpWy3jJA5qsActskRglat5uF2+ QQ/B5oRTYOhAFa4H74ZBJY4n/5wcPDSBlhKzpCA/aDSg+gaYUOrLIZUxA4hhoO/rXZrpinDy8ne HAQHG0o5hkkskm7e X-Google-Smtp-Source: AGHT+IHPjAb1rLSQ43OqGrbcZ/IzSuiJRWw/EpDyVdzrzHNxzjb1Y6QeLs4mCWjkG7KecIPQmqzeGg== X-Received: by 2002:a05:6a21:c94:b0:1e1:a671:7122 with SMTP id adf61e73a8af0-1ed7a5b663fmr11965895637.2.1738235487646; Thu, 30 Jan 2025 03:11:27 -0800 (PST) Received: from localhost ([2401:fa00:8f:203:d4ce:e744:f46b:4fb]) by smtp.gmail.com with UTF8SMTPSA id d2e1a72fcca58-72fe631be3csm1169577b3a.7.2025.01.30.03.11.25 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 30 Jan 2025 03:11:27 -0800 (PST) From: Sergey Senozhatsky To: Andrew Morton Cc: Minchan Kim , linux-mm@kvack.org, linux-kernel@vger.kernel.org, Sergey Senozhatsky Subject: [PATCHv3 03/11] zram: remove crypto include Date: Thu, 30 Jan 2025 20:10:48 +0900 Message-ID: <20250130111105.2861324-4-senozhatsky@chromium.org> X-Mailer: git-send-email 2.48.1.262.g85cc9f2d1e-goog In-Reply-To: <20250130111105.2861324-1-senozhatsky@chromium.org> References: <20250130111105.2861324-1-senozhatsky@chromium.org> MIME-Version: 1.0 X-Rspam-User: X-Rspamd-Server: rspam09 X-Rspamd-Queue-Id: D56ABC000D X-Stat-Signature: xp49rcc6zydprkj4xmm6a6cemg6zj14t X-HE-Tag: 1738235488-635109 X-HE-Meta: U2FsdGVkX1+7+iMVpO8lTbz8lSQ2UMYjAnuSGVih9Y0fQ70ZphYw5i5xPCI3Kkpt2MsvRbjHIpaCQwB9o/rjFYdtm9Vgcku5wKGuGkItFy8SeGLjJ3Eyy/KjW1iFwf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iget39FtAKW8ZcsS3btLesxobLJuZCVbrchqIkS7FeEaRJuHFUoLCp9UXwMGHORa80c60i8mEL+CoHBntN3AMBg6P7Qj/hM6LOSHMcrhQujd2LknyyQjZrit3e2QiQg== 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 9ba3f8d97310..31b653ad6d0e 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; /* @@ -1141,7 +1143,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"