From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C1AD4C432C0 for ; Fri, 22 Nov 2019 10:36:58 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9988820730 for ; Fri, 22 Nov 2019 10:36:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574419018; bh=NCLa/CmFT/n4HyVaQnIGfgA6wAxspxSXxhBEMczoqUQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=TRbMBLF4XOa7MWngLYKIIx73antz1iLlsxgSJ/WJeizlZ4L6LTvRz/f1tPBxe72Fl j6f+NMA9d+9dpifN/dnRxlwDhUzY5pgCRYDO+ss0ZHnzRh5JcVrV07t6QhCpfQzXgS Wkh3aSIPqPey3WCNezEbuhXdgv06hJvvgF6KxRVY= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728476AbfKVKg5 (ORCPT ); Fri, 22 Nov 2019 05:36:57 -0500 Received: from mail.kernel.org ([198.145.29.99]:37542 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727841AbfKVKgz (ORCPT ); Fri, 22 Nov 2019 05:36:55 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 7BB9120707; Fri, 22 Nov 2019 10:36:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1574419015; bh=NCLa/CmFT/n4HyVaQnIGfgA6wAxspxSXxhBEMczoqUQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kmWv9rxpUzInv+QI/pWoJ+jmKrQzC9waOF/2tOoy3CMdcbJPyz/9Np4E6HI0hiwM4 CDSKimznodRSINuMS0b72bs15cNIlq6VWDPHyBq6eEJ1/E6HRuDs3m9H0kCVDDfqEf v6FNCX9VW/WMgRHusYtEbhmRURgJBhVOE4G29fJM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Dan Carpenter , Sasha Levin Subject: [PATCH 4.4 121/159] mei: samples: fix a signedness bug in amt_host_if_call() Date: Fri, 22 Nov 2019 11:28:32 +0100 Message-Id: <20191122100831.264094414@linuxfoundation.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191122100704.194776704@linuxfoundation.org> References: <20191122100704.194776704@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Dan Carpenter [ Upstream commit 185647813cac080453cb73a2e034a8821049f2a7 ] "out_buf_sz" needs to be signed for the error handling to work. Signed-off-by: Dan Carpenter Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- Documentation/misc-devices/mei/mei-amt-version.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/misc-devices/mei/mei-amt-version.c b/Documentation/misc-devices/mei/mei-amt-version.c index 57d0d871dcf71..33e67bd1dc343 100644 --- a/Documentation/misc-devices/mei/mei-amt-version.c +++ b/Documentation/misc-devices/mei/mei-amt-version.c @@ -370,7 +370,7 @@ static uint32_t amt_host_if_call(struct amt_host_if *acmd, unsigned int expected_sz) { uint32_t in_buf_sz; - uint32_t out_buf_sz; + ssize_t out_buf_sz; ssize_t written; uint32_t status; struct amt_host_if_resp_header *msg_hdr; -- 2.20.1