Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3772443imu; Mon, 7 Jan 2019 09:09:50 -0800 (PST) X-Google-Smtp-Source: AFSGD/XgMEkQ65DGyEaK18a8XDkeYXt8x9Hc9RbrsdtJZEEJ5iJsNXhOB/loPWHQjlxEJL9/HWdT X-Received: by 2002:a62:3305:: with SMTP id z5mr64816023pfz.112.1546880990024; Mon, 07 Jan 2019 09:09:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546880989; cv=none; d=google.com; s=arc-20160816; b=WquJUCtlOPOjaJn+3MirORtJeaTw4cYc6XiHIqeCEkeh9QmbcAC3ZdIrHW1ojSPtov hLD9RS5aN/I7jue+sk1F/7wis3GaeenhN1AnO+s1YFr8ahGaVf4CdEoBENTULUYheiWz VPFKd0cMLd5XzK6jKGBQorV4tlxWecPhrvuJ5lQ4jzG3LZaKywTGsMXH4tl+22dtF4T+ UQBVG+Kpd5h3ZtJEgpRFYjsbC63uCPoZBAChMUKXTcRI/HCIPOhuH8tcwO8+mbyfhFse VXlE9cRoTYFkcVSzFkqCmCIoWUjjXiI4Kz20uKxilqEMnE7E8zxL9mT1jddEvOO5AmMD ZsgA== 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:dkim-signature; bh=/v39tygnoa+85AD3HQMcB8/3nYjTDwvqeFXW3UyLiPU=; b=FIWH/teUABENfxjkfTTItT5w/HivGpl8dLUrVB7Bnuxm5sTt5o7i2aZg64aeHQaoTc 0/aS9xHnJSeHCfTpHlToxDi0RZMhdLiXJwvjxm24T3RoRt/xd+lbmlNPVysc6XIRG2Od 1o/JO5qVwjvBMTwiiglWSTir3ac+LljMWRSBSvWyMPtB3lJXqW0+z7F3X1xzGGsB5S9X UJeZWE/bIJy4E4u/T2kWP+205KVw9r81OStDv11l03eDnlp+sFfAaK8KYozh0cgZVtY4 KHXM+EAItGe+7FB6lbJwzDDL8qf5acM6kyZEBcYIv9rF/KC+7wQXOk2Ncv1GgUqe9tWF +ikA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=k3Ds2Nkw; 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 f21si59818815pgv.111.2019.01.07.09.09.33; Mon, 07 Jan 2019 09:09:49 -0800 (PST) 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; dkim=pass header.i=@kernel.org header.s=default header.b=k3Ds2Nkw; 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 S1729435AbfAGMtt (ORCPT + 99 others); Mon, 7 Jan 2019 07:49:49 -0500 Received: from mail.kernel.org ([198.145.29.99]:40606 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728562AbfAGMtq (ORCPT ); Mon, 7 Jan 2019 07:49:46 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.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 D2AB9206BB; Mon, 7 Jan 2019 12:49:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1546865386; bh=V9VwhHQunNcV2LXHJmI0K6hZlfs+rblVZ5SzrGcLhxU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=k3Ds2Nkw74YQVZ5POC01P2EMLZxX+UM6SlFvlBzgJUmU/goh5BCkGYfdrnmHVfV7L 9fLadt8r2PZD/BdtFFxBJbJ8xhD/d9jMHTStexi3V2wq1qAq0a1fR2Ez3OyzJgBSZY 5m5sNrXf48sfEE/nyXfcG5eU8N+lg/pEU4bxBZrU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Mohan Kumar , Dara Ramesh , Sameer Pujar , Takashi Iwai Subject: [PATCH 4.19 075/170] ALSA: hda/tegra: clear pending irq handlers Date: Mon, 7 Jan 2019 13:31:42 +0100 Message-Id: <20190107104501.889671932@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190107104452.953560660@linuxfoundation.org> References: <20190107104452.953560660@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore 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.19-stable review patch. If anyone has any objections, please let me know. ------------------ From: Sameer Pujar commit 63d2a9ec310d8bcc955574220d4631aa55c1a80c upstream. Even after disabling interrupts on the module, it could be possible that irq handlers are still running. System hang is seen during suspend path. It was found that, there were pending writes on the HDA bus and clock was disabled by that time. Above mentioned issue is fixed by clearing any pending irq handlers before disabling clocks and returning from hda suspend. Suggested-by: Mohan Kumar Suggested-by: Dara Ramesh Signed-off-by: Sameer Pujar Cc: Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman --- sound/pci/hda/hda_tegra.c | 2 ++ 1 file changed, 2 insertions(+) --- a/sound/pci/hda/hda_tegra.c +++ b/sound/pci/hda/hda_tegra.c @@ -249,10 +249,12 @@ static int hda_tegra_suspend(struct devi struct snd_card *card = dev_get_drvdata(dev); struct azx *chip = card->private_data; struct hda_tegra *hda = container_of(chip, struct hda_tegra, chip); + struct hdac_bus *bus = azx_bus(chip); snd_power_change_state(card, SNDRV_CTL_POWER_D3hot); azx_stop_chip(chip); + synchronize_irq(bus->irq); azx_enter_link_reset(chip); hda_tegra_disable_clocks(hda);