Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp2951163pxb; Tue, 13 Apr 2021 14:34:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwU27jOk2rdCpLKvmPQNsNmBXqAXBIVh07QVvi9aH5t4cw75GFg3q349iJnEJ2XQQtmJO1u X-Received: by 2002:a17:907:76cb:: with SMTP id kf11mr11307514ejc.472.1618349648556; Tue, 13 Apr 2021 14:34:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618349648; cv=none; d=google.com; s=arc-20160816; b=w8aUjs0T7o5VPyH719oOftsGl+Vzs4N9Er2w0ie22aoibhaoY9pnHevdMywu/5VZ1l gFJ1AZQxN2i8IIk1Us7GWgTG7gQyXRVAhXeWdIWkim6aJyaqSZPePS2B4ACgCDXI7Flc p5OGdvtduy0CmCwJe8UTG+LypeAu3pXUfZtMk6WeNhzR4MGNIQlIZAIiyL2gTnd24H3X PtbFPxb+2Er8sgu7Y8a+fDhxWi7sgl6uHbEpfz62JuvL0ET3Q9qqcbHvZYNmARw8Vfer QMoFjR5fDRxrhNpyUJSwtFd50tuKOyC0R3dFeZxmeRmIr3VmKOk0DR/2tWA1pwUNJK2Q AmmQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=nIl7E1TX/AmjEPOYNmcXuzmbZMqP3dlvzU0KBMbKOp8=; b=i1kXhBF8AJPljqYKHhRQ0/HuoyLYkbi/q2OklHDpX4cnSrJWgfw9tw1aKube7fCAph 0r/AAtGsU02ziS7ovV7NrUQmViGQQ5EXkvcxN0jG07wAMLYNbK0moWsztr9ni99rd13P 6NmJgUwV4+4EcV+3Fo1tL9Ul40jA72xb9mNURx3zM410e5Vz+YA7+g/IUpQUsSoBcHET Bm8W2YUAcx5jba+lmg2JJ3EzepsiRj99jBcSBT7swAcRAV/zFNF8ZNHg6BkUDYeBW8dz PTrKOaIG9p+8y3eKqZej21LkG1lGzkxqFTjGi3+kdRqdZX8aqJAHjMePEVDgcdYwMOis fUaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=nSzO0Tfs; 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=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j3si11592340edn.352.2021.04.13.14.33.45; Tue, 13 Apr 2021 14:34:08 -0700 (PDT) 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=@linaro.org header.s=google header.b=nSzO0Tfs; 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=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344460AbhDMQYU (ORCPT + 99 others); Tue, 13 Apr 2021 12:24:20 -0400 Received: from mail-pl1-f175.google.com ([209.85.214.175]:44921 "EHLO mail-pl1-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343579AbhDMQYM (ORCPT ); Tue, 13 Apr 2021 12:24:12 -0400 Received: by mail-pl1-f175.google.com with SMTP id d8so8495810plh.11 for ; Tue, 13 Apr 2021 09:23:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=nIl7E1TX/AmjEPOYNmcXuzmbZMqP3dlvzU0KBMbKOp8=; b=nSzO0TfsAWG7iNgIdwtsAmUq/KQC/DsxJOS3lEsyXoGzuDRa+1Twzq2OGvh0ORC4Pf lThDb65mpeKuUxaBA4rV0iOYbKPc02HnnHV0wpbswaeTQ0pnXGo+uqvE8PnfjFCxVqK5 zLhT5B7Zf9WHyhiCFme93bh0kILdQQqsJb8x5itcawnECE89Kd7mviwZzJc22hLAkR1V i/AKIiAQDqUObtsRVLLVmYDdyG1F3M3wNmfkJzRfmzwsPwUUSYnDRwDbWn9fRYrTg45x toR2J7tbEiH8McjqjvAYoBVy+yeD8iF71ZVjjXxRklO/Us5B1FiceybdOYAAo6ql26yC Ma0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=nIl7E1TX/AmjEPOYNmcXuzmbZMqP3dlvzU0KBMbKOp8=; b=ENIFwHadjpKtbx9kzLlwuOz0BxPhsodZGEKECNnhgTGUQbDLBPiXwTGTKHueWK3WPt GF1BNBFpuRs8imeGupHKieERKusI8PqHLeLvBRA/3Can9c27i5kVdLoCZc4+katUOjYd spwHSZMkquK20vxla2KmtoK3Sb86nyZqh/WQY+7yewDOs/Ut5rW/ltYpPrA0nGBQJ1Jw PmnWW9zfOWaJE8p4mYRZ/GBBBfqFpFM2NwS6V29Vj0Wc/JHb+jPkInkQJMQiUsL5PTgY 9zAp/5wPReZYvt1kjglowB5VqWFYhfgS46KUJlVjD76MlAMT2iq39kkMYxty/ByC5C6Y MqxA== X-Gm-Message-State: AOAM532c9AxunhII8UJGpQ4kQ6wp3vHdJQIY8SxcuntHjyWt8ttHzL6w O3q2Nbgi/oLuZkBSHyYJXNrjYA== X-Received: by 2002:a17:90a:d3c6:: with SMTP id d6mr838920pjw.25.1618330972307; Tue, 13 Apr 2021 09:22:52 -0700 (PDT) Received: from xps15 (S0106889e681aac74.cg.shawcable.net. [68.147.0.187]) by smtp.gmail.com with ESMTPSA id k1sm12329200pff.160.2021.04.13.09.22.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Apr 2021 09:22:51 -0700 (PDT) Date: Tue, 13 Apr 2021 10:22:49 -0600 From: Mathieu Poirier To: Wei Yongjun Cc: Anshuman Khandual , Suzuki K Poulose , Alexander Shishkin , coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, Hulk Robot Subject: Re: [PATCH -next v2] coresight: trbe: Fix return value check in arm_trbe_register_coresight_cpu() Message-ID: <20210413162249.GA690529@xps15> References: <20210409094901.1903622-1-weiyongjun1@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210409094901.1903622-1-weiyongjun1@huawei.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Apr 09, 2021 at 09:49:01AM +0000, Wei Yongjun wrote: > In case of error, the function devm_kasprintf() returns NULL > pointer not ERR_PTR(). The IS_ERR() test in the return value > check should be replaced with NULL test. > > Reported-by: Hulk Robot > Signed-off-by: Wei Yongjun > --- > v1 -> v2: remove fixes tag. > --- > drivers/hwtracing/coresight/coresight-trbe.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > I have picked up both patches. Thanks, Mathieu > diff --git a/drivers/hwtracing/coresight/coresight-trbe.c b/drivers/hwtracing/coresight/coresight-trbe.c > index 5ce239875c98..176868496879 100644 > --- a/drivers/hwtracing/coresight/coresight-trbe.c > +++ b/drivers/hwtracing/coresight/coresight-trbe.c > @@ -871,7 +871,7 @@ static void arm_trbe_register_coresight_cpu(struct trbe_drvdata *drvdata, int cp > > dev = &cpudata->drvdata->pdev->dev; > desc.name = devm_kasprintf(dev, GFP_KERNEL, "trbe%d", cpu); > - if (IS_ERR(desc.name)) > + if (!desc.name) > goto cpu_clear; > > desc.type = CORESIGHT_DEV_TYPE_SINK; >