Received: by 2002:a05:6358:700f:b0:131:369:b2a3 with SMTP id 15csp2215027rwo; Thu, 3 Aug 2023 06:29:05 -0700 (PDT) X-Google-Smtp-Source: APBJJlF7lR9SdjrWPriq/wMQEDtMZfyUqkhWmZz0jYba/c1kqVlfUYM7sfX9S87dWiijU3gd1Kk/ X-Received: by 2002:a05:6808:2389:b0:3a3:660e:5fed with SMTP id bp9-20020a056808238900b003a3660e5fedmr25578335oib.51.1691069345341; Thu, 03 Aug 2023 06:29:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691069345; cv=none; d=google.com; s=arc-20160816; b=0gu2tGt4tfGnZd4VdVWMBOaOS8OyzCjXgh/B2DozQasE1qbWyT5u7wjpslDJ8DQ6Kk 3L+KY9gbk2CQ1i/67MwK/ehSjffVLnYflKFnMDuT9u41/uxycparCh0jfpsjNFHD8V03 0PUOf83XzOjL6zrXxJJA6BUYpmVGd8Eqxg0AooQZebAtUUrWa+8TsTgcviZzv8Oz7ShI M/5g33zKg/fPtbonREagA79FA8596i7E91VxVOu15BfCCuTNTta4/LSzmP+ibi0F06k3 3cY4a1py9e8G0n11e9pBbwmEYZj1Cofv8MQcTT0Yiuhq2WtUAbQrTGySIW08Ekp1DxHA 3hRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:organization:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=2LOpnYHKnPZWnk2NysKpSusY2wGGBWUBdRRVBOLjH3A=; fh=xtd72CFUTFyCKsXX0Kj4+ry4AYbh4nDdFZgNXbl3cv0=; b=oA32bc0RjNIFdojsnNqrSuRT+lXH22zyB797le3UJw5i3Nt4Ueg2Q5KCnqWWaGw/hy t3vS7Jwf2c71axcvWTy/3MZ4LCLmJid43A08FoEWRfoVD1++qO2XXVYpqreZEXRVS/Iz VnL0TpVCChdpdPTqaecoJI84LF0CFw4IiF7AWIZagPPW+ZhNDWat7trej3Mqv3KAmP9Y Whe2ph38ljQidaz0PXzL/Y/Ws74cHZLaKdToFq5fD8honoB1Q70rDVfSaAg7RDQG+Jcs NszIYVtvSzRNcwVEadxTWTpfKVLQpXozI8QvHXvks0ELIFI99X13NFQ3kQKYEZLz43qG yI3g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="m8R/q0qY"; 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=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s3-20020a63d043000000b00563e1deea73si12322136pgi.39.2023.08.03.06.28.53; Thu, 03 Aug 2023 06:29:05 -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=@intel.com header.s=Intel header.b="m8R/q0qY"; 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=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235677AbjHCL6g (ORCPT + 99 others); Thu, 3 Aug 2023 07:58:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51514 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234690AbjHCL6f (ORCPT ); Thu, 3 Aug 2023 07:58:35 -0400 Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.126]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C8845134; Thu, 3 Aug 2023 04:58:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1691063914; x=1722599914; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=pZ4ZPmvSDy8cgfHE33t4fOkzIy0L7uqmxemDhUrl+uc=; b=m8R/q0qYordoirYdlX+qCoHm2g4KqZDjjmwHEQSjPnUo5lGqfPwPljq5 G6HVxBk7ArjuxJmfOICRNKqZhEJRPGvmVzC+NON52+10wZFE5yo/dWSkL hCaeCcY1s6sKnoClRJws4BFGw5EYmcCtYf7A6NiJTC3+/LdKzCZx19hiE NGHPbdADK3PraWGdlO6p9vCVQnDV3/weYDe/XKJWmqOOUZ6TxY2rudIW+ rhX13fIicRyb11a2K711clQH26XNVmt9IJqiWLaSOmq1q0wLMdV0wqJ6c MITCyu3vXZ7LZLN9v0ssvsX/kwZ0xHFKpVcmeCQCpSNlTBFjk/D3okWv9 Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10790"; a="354770096" X-IronPort-AV: E=Sophos;i="6.01,252,1684825200"; d="scan'208";a="354770096" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Aug 2023 04:58:34 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10790"; a="843570211" X-IronPort-AV: E=Sophos;i="6.01,252,1684825200"; d="scan'208";a="843570211" Received: from smile.fi.intel.com ([10.237.72.54]) by fmsmga002.fm.intel.com with ESMTP; 03 Aug 2023 04:58:32 -0700 Received: from andy by smile.fi.intel.com with local (Exim 4.96) (envelope-from ) id 1qRWyN-00BBt3-0B; Thu, 03 Aug 2023 14:58:31 +0300 Date: Thu, 3 Aug 2023 14:58:30 +0300 From: Andy Shevchenko To: Jiapeng Chong Cc: gregkh@linuxfoundation.org, linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org, Abaci Robot Subject: Re: [PATCH] 8250_men_mcb: Fix unsigned comparison with less than zero Message-ID: References: <20230803084753.51253-1-jiapeng.chong@linux.alibaba.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230803084753.51253-1-jiapeng.chong@linux.alibaba.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE 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 On Thu, Aug 03, 2023 at 04:47:53PM +0800, Jiapeng Chong wrote: > The data->line[i] is defined as unsigned int type, if(data->line[i] < 0) > is invalid, so replace data->line[i] with res. > > ./drivers/tty/serial/8250/8250_men_mcb.c:223:6-19: WARNING: Unsigned expression compared with zero: data->line[i] < 0. Having WARNING: Unsigned expression compared with zero: data->line[i] < 0. is enough. Reviewed-by: Andy Shevchenko -- With Best Regards, Andy Shevchenko