From: Simon Que Subject: [PATCH v3] ata: libata-core: initialize native_sectors in ata_hpa_resize() Date: Thu, 24 Jan 2013 11:57:58 -0800 Message-ID: <1359057478-3920-1-git-send-email-sque@chromium.org> Return-path: Received: from mail-qc0-f201.google.com ([209.85.216.201]:51232 "EHLO mail-qc0-f201.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755405Ab3AXVv7 (ORCPT ); Thu, 24 Jan 2013 16:51:59 -0500 Received: by mail-qc0-f201.google.com with SMTP id a22so600442qcs.2 for ; Thu, 24 Jan 2013 13:51:58 -0800 (PST) Sender: linux-ide-owner@vger.kernel.org List-Id: linux-ide@vger.kernel.org To: sshtylyov@mvista.com, linux-ide@vger.kernel.org Cc: msb@chromium.org, Simon Que Eliminates a compiler warning about uninitialized variable. "warning: 'native_sectors' may be used uninitialized in this function" Signed-off-by: Simon Que --- drivers/ata/libata-core.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index d2b18ea..b185db1 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c @@ -1324,7 +1324,7 @@ static int ata_hpa_resize(struct ata_device *dev) int print_info = ehc->i.flags & ATA_EHI_PRINTINFO; bool unlock_hpa = ata_ignore_hpa || dev->flags & ATA_DFLAG_UNLOCK_HPA; u64 sectors = ata_id_n_sectors(dev->id); - u64 native_sectors; + u64 native_sectors = 0; int rc; /* do we need to do it? */ -- 1.7.8.6