Received: by 2002:ac0:98c7:0:0:0:0:0 with SMTP id g7-v6csp1814650imd; Fri, 2 Nov 2018 00:42:57 -0700 (PDT) X-Google-Smtp-Source: AJdET5cQ5co+jkFqKq5pVpLEiqFNxjWSZaIdK4hbzj8Av65c3jHVI9eDDIzrSFFbZHLLdSqgydr9 X-Received: by 2002:a63:6dc8:: with SMTP id i191mr9712180pgc.215.1541144577163; Fri, 02 Nov 2018 00:42:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1541144577; cv=none; d=google.com; s=arc-20160816; b=qtddMYxbbUQsp6fmkSqRgURrewCW7+wuxuhskydo4dSL8I3ObgtZ9uedJGWXxKV8XO +GHuL8XJo04f6NW/Kn5Cd9ud97+4yLrozlESbxnzYcOh39kXWtrSuGJhiQtTYgo1ckqP eopYl6UcGcrb5bwB+byqW5bBLHv1hsdZtPUa/OAvx+2E8TkiVeR0nesFL39e6/rv2+rM QC/U3sOLBOIyKDQ/LHS/jWE8RaHlQ3ETY3ewOpUPZ8nWlNaIFd5myT26Nqjgi/w+T02J vAALI1/IcE2Yser72aVh5L0vlRguGVMYucvc33ZhCQMafIhMqAn0NdKjVzamCjRT61ra sw5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:subject:cc:to:from:message-id:date; bh=7fA+iPsQzrXszVeuIemuA2yu5ufyQZlrJz7F/nr1JwQ=; b=pGh9rzL0MsJpctsKgSz/F7uWMC7rcJL3GRd7wTC3/FNbCGulUFCiZ4dznmxi4qVBfG NNb/mtrUnp0gdTPxpZVF4KFmbyLT1dq91HqwXuBiJUCgosJ8nlvkjoL9HE9QBNvwg6BG cYjI8pPI+Jzyy0Xzt2jOV/e43KQE4yhXiRkr5jYODLWSssfDej5aDGcxg5AJCen7qbF8 qOYK4jbtV4af0tjCsPk+2I+LW6hATfifw+6+wETAgRoEmMYpZ5sT26CP/tE/EdsVoJSs +jK+gBAQEjFmwlDzxDvgkuEQMGXbeDstNIDugf6JJiQ1R8eKDb40GukwpjmGa14FxpeB B7pg== 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 u128-v6si16430672pfc.145.2018.11.02.00.42.42; Fri, 02 Nov 2018 00:42:57 -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 S1728390AbeKBQsZ (ORCPT + 99 others); Fri, 2 Nov 2018 12:48:25 -0400 Received: from mx2.suse.de ([195.135.220.15]:58508 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728059AbeKBQsZ (ORCPT ); Fri, 2 Nov 2018 12:48:25 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 8538DADF4; Fri, 2 Nov 2018 07:42:10 +0000 (UTC) Date: Fri, 02 Nov 2018 08:42:10 +0100 Message-ID: From: Takashi Iwai To: Rohit kumar Cc: plai@codeaurora.org, bgoswami@codeaurora.org, lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, rohkumar@qti.qualcomm.com, srinivas.kandagatla@linaro.org Subject: Re: [alsa-devel] [PATCH] ASoC: core: Invoke pcm_new() for all DAI-link In-Reply-To: <1541075929-29323-1-git-send-email-rohitkr@codeaurora.org> References: <1541075929-29323-1-git-send-email-rohitkr@codeaurora.org> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/26 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 01 Nov 2018 13:38:49 +0100, Rohit kumar wrote: > > Remove no_pcm check to invoke pcm_new() for backend dai-links > too. This fixes crash in hdmi codec driver during hdmi_codec_startup() > while accessing chmap_info struct. chmap_info struct memory is > allocated in pcm_new() of hdmi codec driver which is not invoked > in case of DPCM when hdmi codec driver is part of backend dai-link. > > Below is the crash stack: > > [ 61.635493] Unable to handle kernel NULL pointer dereference at virtual address 00000018 > .. > [ 61.666696] CM = 0, WnR = 1 > [ 61.669778] user pgtable: 4k pages, 39-bit VAs, pgd = ffffffc0d6633000 > [ 61.676526] [0000000000000018] *pgd=0000000153fc8003, *pud=0000000153fc8003, *pmd=0000000000000000 > [ 61.685793] Internal error: Oops: 96000046 [#1] PREEMPT SMP > [ 61.722955] CPU: 7 PID: 2238 Comm: aplay Not tainted 4.14.72 #21 > .. > [ 61.740269] PC is at hdmi_codec_startup+0x124/0x164 > [ 61.745308] LR is at hdmi_codec_startup+0xe4/0x164 > > Signed-off-by: Rohit kumar Did you check whether all drivers have no side-effect by this change? The hdmi-codec isn't the only driver that has pcm_new ops, so we have to make sure that such a fundamental change wouldn't bring any regressions. thanks, Takashi