Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp3013400pxb; Tue, 12 Jan 2021 04:20:07 -0800 (PST) X-Google-Smtp-Source: ABdhPJxBiLxQJwXQiCZQyfjfQ1vf4V6eHHBog1niT618yD5Nv8PfM5TyUZTg1nXG4Ov2vmJyQyH3 X-Received: by 2002:a05:6402:2cd:: with SMTP id b13mr3340638edx.199.1610454007691; Tue, 12 Jan 2021 04:20:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610454007; cv=none; d=google.com; s=arc-20160816; b=LwRQZNMIccfoeYX7hr4O1Hu+C3Jc/cclLsfWvCtsbvoZwwP1KfFPlgX6WG4gwI2Adi CSU/mwPon04ZQpwpQ9zbzWdVnWqi9+yUOVazw1EW/BLgZV/Boc2ZS448RYlXZe6EGKEF rmbK8LhKZa4lfdvsU8u3rsTC4bZbOFoRIOpMUdI0AbwgCdOECNGBEizRGhEj0crwV4MX 5utatGHRBjo2yEgqdx+7JJBEroYTg1dzVdue06+0fJwtN7C3lhBf6TgPvsK0cEhtmW+Y YyoyrB7XA6fKiml8JjKKRjFBubIUoAYvbhxaYOCk8zZhXZAVzkhGN18K3aYX1ePThBms JLhg== 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 :references:in-reply-to:date:cc:to:from:subject:message-id :dkim-signature; bh=IGnH6pyj0wE74SBCSOC+j1GpxuVSjHdGUM/hxz5Ygfk=; b=hoRAlcUT2iiZ9+Uo19u9TzUgU6dep2ydt+eyG4qrBq2Iz3shYZ9nhwrcvIcPcceJ2W D50Pu9LbLD21m0jLdyrOWTwsStQkZNTAJVTBw91CTxNFG6agRufF5yCvcFpgwm4SlEry gNE54Jz2tC4NvbQ9v2Qk9TnkJd/KyNnJxj3R0P3BiVOzCm1seAPOKBvU9RYwGUONi9Bq tc1i66z04yWnbXVPHt4YKXVfOAEN3+/oxWu2AghGBjuQ5dbsokM4jmxtIaoJwhyRkkgu Evwb4tHw3V3DZkRwanDSMELpr3FMan1xo+RvfmiWr2GlXj3lncYhAm/K0FaeE5N0Kmm/ i+Wg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=V98JukMS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c10si1040595ejf.281.2021.01.12.04.19.43; Tue, 12 Jan 2021 04:20:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=V98JukMS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S2389777AbhALJN5 (ORCPT + 99 others); Tue, 12 Jan 2021 04:13:57 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53588 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732726AbhALJN4 (ORCPT ); Tue, 12 Jan 2021 04:13:56 -0500 Received: from mail-ej1-x634.google.com (mail-ej1-x634.google.com [IPv6:2a00:1450:4864:20::634]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E96B3C061575; Tue, 12 Jan 2021 01:13:15 -0800 (PST) Received: by mail-ej1-x634.google.com with SMTP id t16so2400913ejf.13; Tue, 12 Jan 2021 01:13:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:subject:from:to:cc:date:in-reply-to:references :mime-version:content-transfer-encoding; bh=IGnH6pyj0wE74SBCSOC+j1GpxuVSjHdGUM/hxz5Ygfk=; b=V98JukMSsmuUMqSi9DPSvZdEmlqy0JXdVny3xWqD7owk3L/i9UdbxkGVfwy0Wnscep fEQfC2vyMCxnAkbN0qHmjZ+XSPVNHSq6mu0mO85JsYayKyLEjdL3QernDvCfpb7iAIVx Vc+yF4UaY0k/tUJ+FFOye5sBQMePmiIdBZJAHkUn1B3LvLc+gdsLMZhsq4SCPy4P3xer ShciYCKA6QcG4Z91TMP2GYyjpauXfPjahMYj2BPAafqtZBqVhoBLcuKO1COkBBVxop36 AgedPZaKGywaMv/4AM14NvpbPmUpPcBlPAT8eJn/M3BLZeIN+i0qQexg1G7iZzV5DRlH mx8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:mime-version:content-transfer-encoding; bh=IGnH6pyj0wE74SBCSOC+j1GpxuVSjHdGUM/hxz5Ygfk=; b=YqRahtAV158TFJhIqaQKrWbrOc7kJ5bvXKztBxDsVPhXxACuBOY64p/qPFJxcfoEAO FV/QLcM8t8PrUXRv0yP84EfsnGQUKdkp/cPj+rh4Rreq9d9m8xJd9kVrtkclIAM2VQud IsC6tZnVsMAwdmTKd3Cz1WAx/eY89oA0XxOOkCfC3EQYhNbL2GEKZNRS6L4BtOqyRhm+ hwQsB0XXJlVYba1/ApCdifD2PgwmwYdgtSiaddr+QL0bDfwY5CHiXwvWvhXO+dlj54xH zZUpXTMbUJ8LqQVmj3L7t0ixdCBwZ0A/b4Ix7AwxgqfIpVlqpd2xOqU5l/U3mv7J4DBG upzw== X-Gm-Message-State: AOAM5319X7VmUfJg8HMkW4A6P1Gh+UYaHaolhHMBjg1qA+v7MCqqQn5J T1cx3qT7sq3DlrnTOKcqZho= X-Received: by 2002:a17:906:f949:: with SMTP id ld9mr2562029ejb.401.1610442794667; Tue, 12 Jan 2021 01:13:14 -0800 (PST) Received: from ubuntu-laptop (ip5f5bfcff.dynamic.kabel-deutschland.de. [95.91.252.255]) by smtp.googlemail.com with ESMTPSA id t8sm919063eju.69.2021.01.12.01.13.13 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 12 Jan 2021 01:13:14 -0800 (PST) Message-ID: Subject: Re: [PATCH v2 1/2] scsi: hisi_sas: Remove unnecessary devm_kfree From: Bean Huo To: John Garry , alim.akhtar@samsung.com, avri.altman@wdc.com, jejb@linux.ibm.com, martin.petersen@oracle.com, ebiggers@google.com, satyat@google.com, shipujin.t@gmail.com Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, Bean Huo Date: Tue, 12 Jan 2021 10:13:13 +0100 In-Reply-To: References: <20210111231058.14559-1-huobean@gmail.com> <20210111231058.14559-2-huobean@gmail.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2021-01-12 at 09:03 +0000, John Garry wrote: > On 11/01/2021 23:10, Bean Huo wrote: > > From: Bean Huo > > > > The memory allocated with devm_kzalloc() is freed automatically > > no need to explicitly call devm_kfree. > > > > This change is not right - we use devm_kfree() to manually release > the > devm-allocated debugfs memories upon memory allocation failure for > driver debugfs feature during probe. The reason is that we allow the > driver probe can still continue (for this failure). > > Thanks, > John yea, I see, probe didn't deal with ENOMEM error. will drop this change. thanks. Bean