Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp2059740rwb; Sat, 8 Oct 2022 01:17:01 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4peJi3xvkId5hWyXnWshcpi+EWL1bwicOTJh7qEBKy9esuw8kDgqASpXM6YywQkoZYjCha X-Received: by 2002:a17:906:8b81:b0:77e:cd92:9d with SMTP id nr1-20020a1709068b8100b0077ecd92009dmr6854903ejc.484.1665217021243; Sat, 08 Oct 2022 01:17:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665217021; cv=none; d=google.com; s=arc-20160816; b=m22dMeza4C8Le+K4A1WTxWhdoSAlyavztS5jR8Qh/P95oa3rX/+J7nI8tdYxn/Tg6S FzPdcWaBQ+4XlN4OF/7e5JDLIYGhCPqGqN6Jt0pqgtWLYT6zLwMdR6FZyECIT2IBVGiB Z+6U/2fmqbr5z/dkgcZre0wzvbVd2mKYmgGtj120+v61LJlo4WCjkbOh1aynunbQINi6 E273IlEvMdgd96JPUz9XjP3mrHms29Oqoagqw/bnkE9jsyuD1zsIzFE6JZ8/w02fuVmP /oqGAIR+kwc7/XHkmtUhnTZLlefACNRt7m//cmhSTYSU09MMUspaZlHzbuPv4KvV22G2 52IA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=yy1hrG2GpPBkvn2HfQINffR+3hxzGXt2IgtYJPN1P7E=; b=D988We3BL3o0AkCXUTYljaamKKuac8NA2gBUPYCtI9VldBNL8CpJYtQTEjNV0cnsGe yaosgfPZbFDb6xd3/nwH/CUVKX3xbfhc6dp9Tzy6f7X+uWtrmyTgHCcbT31dhkGpnvD+ QpWMiFeUSHHCc1qE2ZAH4CrxoaKiV4TgZoyqXCJDkptOW8MgCHJuFVR7AC7bepnrC6L9 oALJUC2S/qLZtHvaBZVdgFXCbOe1z6sRPMvUCA4luobse0+gUto6MNJdhqMaU+aNUFkj 27REPHDfU0JPgp7MtYQbGemgJorJWdklSLc2tjGBnGa0fYlPX0qeLB685rMIu+YnqiR+ +6DQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=auD42bYp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i17-20020a17090685d100b0078210c21ecesi3637588ejy.304.2022.10.08.01.16.36; Sat, 08 Oct 2022 01:17:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=auD42bYp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229668AbiJHHqv (ORCPT + 99 others); Sat, 8 Oct 2022 03:46:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42510 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229553AbiJHHqu (ORCPT ); Sat, 8 Oct 2022 03:46:50 -0400 Received: from mail-pg1-x52d.google.com (mail-pg1-x52d.google.com [IPv6:2607:f8b0:4864:20::52d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 866E159246 for ; Sat, 8 Oct 2022 00:46:49 -0700 (PDT) Received: by mail-pg1-x52d.google.com with SMTP id r18so6419536pgr.12 for ; Sat, 08 Oct 2022 00:46:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=yy1hrG2GpPBkvn2HfQINffR+3hxzGXt2IgtYJPN1P7E=; b=auD42bYp121ROiFoAixlBntsidbY1hawD9jksLlHUfCGs+g1S33boZlc8IG52tq3LN DX3zkFHJMskR9WbEfqaIU3wWP2PYec++sWTNaxJ+jm/6Sc/mlQCL57/xC3g6z8bdDGzp EqRUliodvHvnOoW98Z6z+P8C9u0UOxm965lxZO0jk3o0DBucSnhvgc/Noh0foIWdCPo1 IpDQTDjQ1Xb46qq47hdQJsExw1k6iJAlOma49I3UhOIkTQqVIW3vnwh2GfMB+HZKRAC9 YNZ+9lFYEDDf82yOzWn7uDWc+lc0U/2O7VNLesgUBHl+ixcvrRL2tAfsnNKxAG71wtVg J12Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=yy1hrG2GpPBkvn2HfQINffR+3hxzGXt2IgtYJPN1P7E=; b=Z2nPZ034H9TlITr7Be9SHs9DbWFeNLfX/Hexk7zNpLWu9OZlGfj/JGCZ1WCj3M6NaP 6C38e5wYcwiM2ec2v10P8Md7AIziI0Xs6B823ZeOnhc0MjEtNsw9CuRCKwvSni6fJ2Hh T8Lx7rGpE3kCYKswyojQN6qrSLMqI8FbwKFbtkqb0Vx5428C+rkvaYCSY11ZIa3lA+VY bD7H+ZALPFSv4izpnT2IfBKSdx5NSZzvF9lSuuiuvM5oZhdF9M/GZ4qC7faBfdoTP59l IOtjAY3rW5c3uEhppwSsdHHR0jvTcNdqErnzwXrYW9NJ81P51Swc8C+hewpcX0LRbOdA Ia1w== X-Gm-Message-State: ACrzQf3GND6otX0YPR+aFPVfQ02dUQnSqIIb6cHaAlE8NQFPOYSaQyWC CAIflQoQ2F9IT06CTt5QWHk= X-Received: by 2002:a63:581e:0:b0:43c:29a0:6390 with SMTP id m30-20020a63581e000000b0043c29a06390mr8029983pgb.552.1665215209070; Sat, 08 Oct 2022 00:46:49 -0700 (PDT) Received: from localhost.localdomain ([193.203.214.57]) by smtp.gmail.com with ESMTPSA id x16-20020aa79a50000000b005365aee486bsm2852880pfj.192.2022.10.08.00.46.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 08 Oct 2022 00:46:48 -0700 (PDT) From: yexingchen116@gmail.com X-Google-Original-From: ye.xingchen@zte.com.cn To: miquel.raynal@bootlin.com Cc: richard@nod.at, vigneshr@ti.com, wsa+renesas@sang-engineering.com, linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, ye xingchen Subject: [PATCH linux-next] mtd: replace strcmp with sysfs_streq Date: Sat, 8 Oct 2022 07:46:43 +0000 Message-Id: <20221008074643.308969-1-ye.xingchen@zte.com.cn> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: ye xingchen Replace the open-code with sysfs_streq(). Signed-off-by: ye xingchen --- drivers/mtd/parsers/cmdlinepart.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mtd/parsers/cmdlinepart.c b/drivers/mtd/parsers/cmdlinepart.c index b34856def816..6a401e0b1b95 100644 --- a/drivers/mtd/parsers/cmdlinepart.c +++ b/drivers/mtd/parsers/cmdlinepart.c @@ -154,7 +154,7 @@ static struct mtd_partition * newpart(char *s, } /* if slc is found use emulated SLC mode on this partition*/ - if (!strncmp(s, "slc", 3)) { + if (sysfs_streq(s, "slc")) { add_flags |= MTD_SLC_ON_MLC_EMULATION; s += 3; } -- 2.25.1