Message ID | 1528354129-5023-1-git-send-email-akshu.agrawal@amd.com (mailing list archive) |
---|---|
State | Accepted |
Commit | 6e56e5d04191aa20e08430dcb203c081fa247e93 |
Headers | show
Return-Path: <alsa-devel-bounces@alsa-project.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B1C9560375 for <patchwork-alsa-devel@patchwork.kernel.org>; Thu, 7 Jun 2018 06:49:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 93151296FA for <patchwork-alsa-devel@patchwork.kernel.org>; Thu, 7 Jun 2018 06:49:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 86A4329729; Thu, 7 Jun 2018 06:49:36 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DB695296FA for <patchwork-alsa-devel@patchwork.kernel.org>; Thu, 7 Jun 2018 06:49:34 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 9C40D266E76; Thu, 7 Jun 2018 08:49:32 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 95762266E77; Thu, 7 Jun 2018 08:49:30 +0200 (CEST) Received: from NAM03-CO1-obe.outbound.protection.outlook.com (mail-co1nam03on0086.outbound.protection.outlook.com [104.47.40.86]) by alsa0.perex.cz (Postfix) with ESMTP id EC101266E0E for <alsa-devel@alsa-project.org>; Thu, 7 Jun 2018 08:49:26 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=irWWIiHhRYRe7/JMl+nHUksh8mL1vFZiN+318G9MwRw=; b=jvMEjGs4VhuWfuqQlSsJnjMUPKaMcLbupvuAG/mQTgZOjB8HCaoAs/hfkoebZ+usOAYt6z7m0k+MUn8/6BDa8QFIDn/+c/TEFGOrgzQn3q1EU36OMuYgGFBtU6BZlhGId5gvgcRNOzZmEpk619AidP9ZXJAT7XVxtoEwdi78WGI= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Akshu.Agrawal@amd.com; Received: from akshu-HP-EliteBook-745-G2.amd.com (202.56.249.162) by BL0PR12MB2355.namprd12.prod.outlook.com (2603:10b6:207:4c::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.841.14; Thu, 7 Jun 2018 06:49:14 +0000 From: Akshu Agrawal <akshu.agrawal@amd.com> To: Date: Thu, 7 Jun 2018 14:48:43 +0800 Message-Id: <1528354129-5023-1-git-send-email-akshu.agrawal@amd.com> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 X-Originating-IP: [202.56.249.162] X-ClientProxiedBy: MAXPR0101CA0038.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a00:d::24) To BL0PR12MB2355.namprd12.prod.outlook.com (2603:10b6:207:4c::33) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(48565401081)(5600026)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:BL0PR12MB2355; X-Microsoft-Exchange-Diagnostics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F3Qs1TEj2SI6R+T9ncrz8iY/7/dYhfrz39ebbGmi5fKRGMXenmhC20rqPZ8yjqf5sZL3PpqSi6P9Fn+iRV844//v45yD0qlNEgj7HFSy73hVyQgIPKZDPgGOtY3b56ahu/ThDyB863c4fH3gaMmRdgbDz9HPdUSdQ+smgxBcbjuYQ+1CvnHGAxTzFo4R2VJGYwV0Gl160/Tfx2c+B+oFUNRSWmJ4e5eDJwu3GXq3Gkhgmdm/x3HOrbsVUH8IueUqqVA2qCTHjbyBnbstLqfV4BZXGHcKd5ZwkItNLgvy6QqsONTrCnLM2ekYpcgqhs2WFpJH6qryGx+PCz0RCuG+tlInZaXka70BpJYVhh+O+SRSFcj; 4:MUd4aCv6Evn3Iq0PwG+JXzosrpcJR5jMh1z+IplVX/6iyS/9q6+BLSpq/sW7YTepy94KGhgEBIR2uT0NF6ASaSDzrtHyfgrGTKLP4pY77y3AFSYaiM3s+9lzrLG/F/gmPhCBO5TnXvHnPE0UiguXBxx0cV6joqg+xfUAVUhHhk1nktKtrWRiuY0WqJ4ph9QmCJ9+Xt7F7dOjll+1yLYl8u93cGjnye1MwyeFn+mIqvrYRhWeVViyEOGWPHxU0NPwqIETv82SvrpplxQM4C4DlwrYp/x2+GsgQi20JhzQYT+RZm5RAEFb9r4RnZ7U6OFU X-Microsoft-Antispam-PRVS: <BL0PR12MB2355D2E1FC24FE00360BDF96F8640@BL0PR12MB2355.namprd12.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(767451399110); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(10201501046)(3002001)(93006095)(93001095)(3231254)(944501410)(52105095)(6055026)(149027)(150027)(6041310)(20161123558120)(20161123562045)(20161123560045)(20161123564045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011)(7699016); SRVR:BL0PR12MB2355; BCL:0; PCL:0; RULEID:; SRVR:BL0PR12MB2355; X-Forefront-PRVS: 06968FD8C4 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(346002)(396003)(376002)(366004)(39860400002)(39380400002)(189003)(199004)(53936002)(44832011)(54906003)(486006)(386003)(59450400001)(316002)(7736002)(5660300001)(25786009)(86362001)(956004)(2616005)(16586007)(476003)(66066001)(305945005)(6666003)(47776003)(478600001)(106356001)(4326008)(6486002)(39060400002)(109986005)(53416004)(1671002)(105586002)(36756003)(26005)(6116002)(3846002)(52116002)(51416003)(7696005)(97736004)(8676002)(72206003)(48376002)(81166006)(16526019)(186003)(81156014)(68736007)(8936002)(2906002)(50226002)(50466002)(266003); DIR:OUT; SFP:1101; SCL:1; SRVR:BL0PR12MB2355; H:akshu-HP-EliteBook-745-G2.amd.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: amd.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BL0PR12MB2355; 23:vzRgk0WwBZRYjt7cWcqGtUlEPoNwnVFyrfWmXbCwQ?= =?us-ascii?Q?t4Tcc8o3PcsQoY8P5VQX/JmGzGTWRudIuNM9bDpuX7wBsD0xf5BQ7AkeYbp4?= =?us-ascii?Q?mmZIEkGlOhwcC5iwlOnzf+v96bFt84TSiTGO17oc1EpPAfA6HZzf1qK/6Qz5?= =?us-ascii?Q?DtU28sfyPoEHV3BbUUJZNBCIfo5msRIEfBpSQvCZ9UtWD/VgeI8TR/ONvB/e?= =?us-ascii?Q?VoLd8t2jF4uXFqL0tNFVNQyw4Geb6ExgflSL91NL1xOqBJ2E8rhUZ4jwPWqy?= =?us-ascii?Q?4R7xPDoClfHMv7zStLrbGd76tLXiskiBSj2XCF8Dz740knHBTtyw2PJfXDxh?= =?us-ascii?Q?M2LMhVH4nMqDkQTOxvhcLNFiItmaTX5ygXQlvtar/lqoLoDDwVLKumBTsaJ0?= =?us-ascii?Q?O2qkERW6pV32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oft-Antispam-Message-Info: DE649gLIxubY2XhMTcRo75QqTVBF4uKUtsTgv9xoFou9Sd2Nr4sdPqga7h1snqMnQk/+NMpJhu1mQ1BN5BTDzbqOh9tNQms3wid132C8mUCJJYa0ku30ccdX1KZYnXtKBzTwovk17+faTZm36MQAoaPmn6QR9HJXSCQJfmukzLxNrtrtBovNIi12n0H6P7EC X-Microsoft-Exchange-Diagnostics: 1; BL0PR12MB2355; 6:qwQBv8JkFsDptWnaFzPDnV66ro0HLM6bTHjvfUICRtltfpEdwHxXDgwSfXonI1+ppE3f3rI6RNA45d0HuTwPoYPiqgGEbC6NpzX5fvX4PI/cXPfnnoVCDiL1ttd44az6KbwolJDSKzov2vm47kAlqhBVEmle+kdaHe7zNeT/IOctER0m86hquVF28T1GX3xEgnB133AqArkiInC6wrnSAPhf7qG7wyvXXDuCDJxIXVceoYbwpxH6ZgwI+jxIESoeOqu/o8ib00gjEklIl8aaAPZ/vKSj2Qid4rX/tDjgXoGxn8BJBAdRtkCQcZEcWAbuKNWyIol40nvEAqo+URWHk6kj+PgPvDsOrGZjlMhlxw+0/uY24Xr50NnPoj2hnn5NQ0y+BKNzvTmiGCvTY9tbVf3lk+Kq27kt6nTegt9oEV9dvszCAucIqGN+qRp0eG5p3rqEvPimMrICaD3kg+FPfQ==; 5:wuNto0jHhUkdJ8tZ1ffYMvGRuiav/+EpuIXDHy53W/V4cbNhNzo5Ct5IAlEANtQ/aPGujY0T1YC8dwy1DlIPYqJcTRepugDZW7PYAjJPWLjl95M+qcswyf8a0t685gZEMXCIPiG4fSUsxAVuMVIVa0TYVtGi3hKm6d+9gViQCD4=; 24:tGy5q/IO7WywmTqORfb9PSN4aZiSRWZpSrwfiSPNrtFz31Z7jArsraMG4vVi8yZ7dO/I0Vcnqadf2apqY0fCaE0sBPZzGfeNeLGDPyegTJc= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BL0PR12MB2355; 7:8jFW4NRF+Af/GwIbI1QD4uL9isC+FZKX8q2LMxM3+iQd7dIZhH/d8G2Urgif0Y39I5MUQExQmg62/vgvr4jTc2WdEwcpU6LCDYP49GavQMRCVbCWYiqYHSPLcV3m5Z3AbNQ5RGpaOywd/jsko62TNA6z8sOwGtVCkq2acDTizgo89j6/KHYqNwo9aGmxIMUk2k5n/5sn/0U8PlsjZC20/nvcmlB1wlRKoqCcS7MQ7aULp6it6ygSqTQaYqaeIqzP; 20:wed8mHd9E+mXe9FWev0hxkVLrDkfQ5U13//K8+iDJ89H3dUyXyvNKOwxdAHVAxEiy1/aAlY+C8h7kBNLq14MlXziR3k5IlAHxsU2d39K8TmAYW3b+wBlYvfzCrpiYsB3dmBfRRyOjPCHfov0biDnF3x4UvFwP6nc1pSwg2iA4NFZm0GJk05oZXAPICWQIvtQWeKHKzYjU201IRM9njSyyPdQ+HIHvPVDNXvLm5G+C0Rl2wnJY7rNvQKdIQ7dt22Y X-MS-Office365-Filtering-Correlation-Id: 1b565575-d2d0-4c12-410a-08d5cc42cd91 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Jun 2018 06:49:14.1824 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 1b565575-d2d0-4c12-410a-08d5cc42cd91 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR12MB2355 Cc: "moderated list:SOUND - SOC LAYER / DYNAMIC AUDIO POWER MANAGEM..." <alsa-devel@alsa-project.org>, open list <linux-kernel@vger.kernel.org>, Takashi Iwai <tiwai@suse.com>, Liam Girdwood <lgirdwood@gmail.com>, djkurtz@chromium.org, Mark Brown <broonie@kernel.org>, "Mukunda, Vijendar" <Vijendar.Mukunda@amd.com>, Alex Deucher <alexander.deucher@amd.com>, akshu.agrawal@amd.com, Guenter Roeck <linux@roeck-us.net> Subject: [alsa-devel] [PATCH 1/2] ASoC: AMD: Add NULL pointer check X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" <alsa-devel.alsa-project.org> List-Unsubscribe: <http://mailman.alsa-project.org/mailman/options/alsa-devel>, <mailto:alsa-devel-request@alsa-project.org?subject=unsubscribe> List-Archive: <http://mailman.alsa-project.org/pipermail/alsa-devel/> List-Post: <mailto:alsa-devel@alsa-project.org> List-Help: <mailto:alsa-devel-request@alsa-project.org?subject=help> List-Subscribe: <http://mailman.alsa-project.org/mailman/listinfo/alsa-devel>, <mailto:alsa-devel-request@alsa-project.org?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/sound/soc/amd/acp-pcm-dma.c b/sound/soc/amd/acp-pcm-dma.c index 7720384..1458b50 100644 --- a/sound/soc/amd/acp-pcm-dma.c +++ b/sound/soc/amd/acp-pcm-dma.c @@ -773,7 +773,8 @@ static int acp_dma_hw_params(struct snd_pcm_substream *substream, if (WARN_ON(!rtd)) return -EINVAL; - rtd->i2s_instance = pinfo->i2s_instance; + if (pinfo) + rtd->i2s_instance = pinfo->i2s_instance; if (adata->asic_type == CHIP_STONEY) { val = acp_reg_read(adata->acp_mmio, mmACP_I2S_16BIT_RESOLUTION_EN);
Fix crash in those platforms whose machine driver does not expose platform_info. For those platforms we rely on default value and select I2SSP channel. Signed-off-by: Akshu Agrawal <akshu.agrawal@amd.com> --- sound/soc/amd/acp-pcm-dma.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)