Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp4284096pxb; Mon, 8 Feb 2021 12:23:55 -0800 (PST) X-Google-Smtp-Source: ABdhPJxJMHWjD1VR8ULMXeOkNyydFOtLakCQWk5Nb1T7IdYxIYoZKVWc94+0AUMZmPG4/k88tscN X-Received: by 2002:a17:906:d922:: with SMTP id rn2mr19367943ejb.414.1612815835678; Mon, 08 Feb 2021 12:23:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1612815835; cv=none; d=google.com; s=arc-20160816; b=etN3ODObOXXpYtYNPV6//PaZuAQmX16c0eDQ5tcUtrCCphLsqbLsocgLntCG58gIxh CWx/wDZx/+7wJ9n/7RuKZElS4lDBujM5/8eA8kMidAunDWQRxnFIzzyCHK/kiE4JRZ1t Fm9s/ZBYZdX3eXWQeTnkPlVERTTVFINxTnJA8PV5JLNqhsC7/YhFQm7MXQDL1jstJoiQ YMT1ablbmkJ1kXXorkHxP/BzcPC6vbl2Q9uf0mv/pBGhM7UAvyJCYMRNbWYjJ1mFJDFE O1DMEIJ9IKrY2tBDT2g/crV8kRWYbfHCQjmXPKq7v9IaycdIQjz3RkeQBQJccwDRTVC8 BffA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=ESN4pvY7wPX52ORAOP/fxbyeolt7DhvyEd465ssL220=; b=h1NDQ9m0tODHr8nG+RWAoSj+gG6jYrX3itVWgH85GsbEYUhdK+4xfwJ4Lk3SBy9/58 +GSLMtfr6X3AfSe9/yk1Ap45xaNcL5A6Pvx7K8cJ/q9kFZpvpORYIEC1B7vHCzG1Sy0H udygLacoBOxwIOd1YGka4QjOWokzHt5CfnYWtxyHGsHYSa3uDsKU9FuMKG6gAL9HOV1D grcQz+LnUHpFu7kssV21rgCSfXdksD5ZKJSLLOsJ1Vi3sa7kP25BEJCE2UckBt1vJUZP EyhpGOT2XhXMcu7UcgGb5YCTuKUwL67EFAKJ1aXoVRuGYMvqxT7GgQK+e7ZZcU4Lh3XX ocnQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2020-01-29 header.b=sycL5PL1; 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=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id qc23si11867323ejb.467.2021.02.08.12.23.31; Mon, 08 Feb 2021 12:23:55 -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=@oracle.com header.s=corp-2020-01-29 header.b=sycL5PL1; 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=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236852AbhBHUXA (ORCPT + 99 others); Mon, 8 Feb 2021 15:23:00 -0500 Received: from aserp2120.oracle.com ([141.146.126.78]:58644 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235961AbhBHS7G (ORCPT ); Mon, 8 Feb 2021 13:59:06 -0500 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 118IfOSq187494; Mon, 8 Feb 2021 18:58:21 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=corp-2020-01-29; bh=ESN4pvY7wPX52ORAOP/fxbyeolt7DhvyEd465ssL220=; b=sycL5PL1XXUIZqG1Z3/xGDuLePm4jSOfCtLq4T6/IoPXvaXpwgLSB4VuYUsMMuW5R+K6 dJM9A+BaGm46Kmjj0Y7msU6oy7x86LQUmHyw0KPiTCgrmQzyWCqrpr488KZ+LDcc3tOs o7PlqtISe+cK5RFPLclcx1xyiREpvBa/q0FNjiBnlZShIHFGqv3jdIF1hMp/wLOhugII AbuJbJEof3gbweeXwxHrY8PZ+fuecI2972bWimhSjDgkWbyvQfJ9rlBYhGG8fRvQgZTX /rhTM5rpguYe5PGtLGrKkW+dYPVoOD8nBP43+8UtHqVsTn0BNZiRI3od0CNT4PZVCZR1 Zw== Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by aserp2120.oracle.com with ESMTP id 36hk2kd0mj-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 08 Feb 2021 18:58:21 +0000 Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 118IdpJX053151; Mon, 8 Feb 2021 18:58:19 GMT Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserp3030.oracle.com with ESMTP id 36j4pmqbbs-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 08 Feb 2021 18:58:19 +0000 Received: from abhmp0002.oracle.com (abhmp0002.oracle.com [141.146.116.8]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 118IwH2R029843; Mon, 8 Feb 2021 18:58:18 GMT Received: from kadam (/102.36.221.92) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 08 Feb 2021 10:58:17 -0800 Date: Mon, 8 Feb 2021 21:58:10 +0300 From: Dan Carpenter To: Ioana Ciornei Cc: gregkh@linuxfoundation.org, laurentiu.tudor@nxp.com, linux-kernel@vger.kernel.org, Ioana Ciornei Subject: Re: [PATCH 1/3] bus: fsl-mc: Fix test for end of loop Message-ID: <20210208185810.GM20820@kadam> References: <20210208170949.3070898-1-ciorneiioana@gmail.com> <20210208170949.3070898-2-ciorneiioana@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210208170949.3070898-2-ciorneiioana@gmail.com> User-Agent: Mutt/1.9.4 (2018-02-28) X-Proofpoint-IMR: 1 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=9889 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 adultscore=0 mlxlogscore=999 malwarescore=0 bulkscore=0 phishscore=0 spamscore=0 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2102080114 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=9889 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 malwarescore=0 priorityscore=1501 clxscore=1011 impostorscore=0 lowpriorityscore=0 bulkscore=0 suspectscore=0 spamscore=0 mlxlogscore=999 adultscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2102080114 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Feb 08, 2021 at 07:09:47PM +0200, Ioana Ciornei wrote: > From: Dan Carpenter > > The "desc" pointer can't possibly be NULL here. If we can't find the > correct "desc" then tt points to the last element of the > fsl_mc_accepted_cmds[] array. Fix this by testing if > "i == FSL_MC_NUM_ACCEPTED_CMDS" instead. > > Fixes: 2cf1e703f066 ("bus: fsl-mc: add fsl-mc userspace support") > Signed-off-by: Ioana Ciornei > Signed-off-by: Dan Carpenter Generally the tags are expected to go in chronological order: Fixes: commit Signed-off-by: Author Acked-by: Whoever Signed-off-by: Maintainer regards, dan carpenter