Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp2517068imm; Mon, 24 Sep 2018 05:48:14 -0700 (PDT) X-Google-Smtp-Source: ACcGV61Y00I4HfpMChX3KEsFEVHh+VbKk7S89ssb+J62xRxbUEdk7si8qxhr+UaNJzS38gRtTP18 X-Received: by 2002:a17:902:6b4b:: with SMTP id g11-v6mr10304640plt.19.1537793294517; Mon, 24 Sep 2018 05:48:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537793294; cv=none; d=google.com; s=arc-20160816; b=YTBNkW+mos7AnmmTuxsbBE+fVB+rA3W0YgtDGxGJ0S0MdCwwKVWIXOCAYnSP5uhoVv 8wad5QSd4EQQOgjQJgs2ld4J5tibEz0T0Zwiu396xWQm9DfvIyT0uDNpmwEzjuiTEZfL OQYH+QH0XbsI/RRx9Pq7tEvXcfAu5FNAy6lyEtocmGuJBc+5yrFgbIcMljs0RfNLeWn8 mW+p9GfxBBEvDQvzA4t7O/B5sX6x4N55sxt6r17xafZz9s3/XKZTPntRGVFLvvrtkwkO hciC4jGkS9DnnwdAnv47wLfr6uQv1enqL+TIabzM9KMjl1DxTToVjaVizS2NxSPymY85 VZkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from; bh=4ozPr1mDGqwdZ+xpCJkCtgDo8p4ivtDvUUCVHJk57Qo=; b=0Nhv30AIBJKOMG/+bnZZPspBmqgxt4nN53cMWs6A4coKgmdWLN5N0oNPrf/1ni90gb 7x7rJNXfttj37+1do69YJEBD0GLhE9ij2Gdo4auazTTvgB01zBa4GaMLXtdmEfidQYq2 V3s4F1XpXj//TQr+S3X0xb++IM8dKIx5KlhaePiZFRa2GqyfiezHK1cbr04enLd3us7q Sv/uIhrJByUSY6toQKwNKxAKFfKvLuiD2Xcg3zq4ShEolUfFzkWSRdL1Wb9cXmQ+Sdc3 PLXHkWFxl9EiPUqskW/77Q0CWwf8BDXmtuksfBLiPGEKAQ4bv979MeY/7Oa3RADevo3N s4DA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k130-v6si35637747pfc.282.2018.09.24.05.47.59; Mon, 24 Sep 2018 05:48:14 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389382AbeIXSrz (ORCPT + 99 others); Mon, 24 Sep 2018 14:47:55 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:59852 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730401AbeIXSrz (ORCPT ); Mon, 24 Sep 2018 14:47:55 -0400 Received: from localhost (ip-213-127-77-73.ip.prioritytelecom.net [213.127.77.73]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id B3F80109A; Mon, 24 Sep 2018 12:45:55 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Shuah Khan , Pintu Agarwal , Li Zhijian , Sasha Levin Subject: [PATCH 4.18 212/235] selftests/android: initialize heap_type to avoid compiling warning Date: Mon, 24 Sep 2018 13:53:18 +0200 Message-Id: <20180924113124.916353987@linuxfoundation.org> X-Mailer: git-send-email 2.19.0 In-Reply-To: <20180924113103.999624566@linuxfoundation.org> References: <20180924113103.999624566@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review 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 4.18-stable review patch. If anyone has any objections, please let me know. ------------------ From: Li Zhijian [ Upstream commit cc7c673032fc7427087e74b75f732b43db38a256 ] Initialize heap_type to ION_HEAP_TYPE_SYSTEM to avoid "used uninitialized" compiler warning. heap_type gets used after initialization, this change is to just keep the compiler happy. root@vm-lkp-nex04-8G-7 ~/linux-v4.18-rc2/tools/testing/selftests/android# make make[1]: warning: jobserver unavailable: using -j1. Add '+' to parent make rule. make[1]: Entering directory '/root/linux-v4.18-rc2/tools/testing/selftests/android/ion' gcc -I. -I../../../../../drivers/staging/android/uapi/ -I../../../../../usr/include/ -Wall -O2 -g ionapp_export.c ipcsocket.c ionutils.c -o ionapp_export ionapp_export.c: In function 'main': ionapp_export.c:91:2: warning: 'heap_type' may be used uninitialized in this function [-Wmaybe-uninitialized] printf("heap_type: %ld, heap_size: %ld\n", heap_type, heap_size); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ CC: Shuah Khan CC: Pintu Agarwal Signed-off-by: Li Zhijian Signed-off-by: Shuah Khan (Samsung OSG) Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- tools/testing/selftests/android/ion/ionapp_export.c | 1 + 1 file changed, 1 insertion(+) --- a/tools/testing/selftests/android/ion/ionapp_export.c +++ b/tools/testing/selftests/android/ion/ionapp_export.c @@ -51,6 +51,7 @@ int main(int argc, char *argv[]) heap_size = 0; flags = 0; + heap_type = ION_HEAP_TYPE_SYSTEM; while ((opt = getopt(argc, argv, "hi:s:")) != -1) { switch (opt) {