From patchwork Mon Mar 3 22:45:18 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aaro Koskinen X-Patchwork-Id: 3757561 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 9245B9F1EE for ; Mon, 3 Mar 2014 22:44:42 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id BE9D620416 for ; Mon, 3 Mar 2014 22:44:41 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2D6B12041B for ; Mon, 3 Mar 2014 22:44:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755143AbaCCWoj (ORCPT ); Mon, 3 Mar 2014 17:44:39 -0500 Received: from filtteri1.pp.htv.fi ([213.243.153.184]:33637 "EHLO filtteri1.pp.htv.fi" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754951AbaCCWoj (ORCPT ); Mon, 3 Mar 2014 17:44:39 -0500 Received: from localhost (localhost [127.0.0.1]) by filtteri1.pp.htv.fi (Postfix) with ESMTP id 699C421BEB6; Tue, 4 Mar 2014 00:44:37 +0200 (EET) X-Virus-Scanned: Debian amavisd-new at pp.htv.fi Received: from smtp6.welho.com ([213.243.153.40]) by localhost (filtteri1.pp.htv.fi [213.243.153.184]) (amavisd-new, port 10024) with ESMTP id OzG60MsZaMrj; Tue, 4 Mar 2014 00:44:33 +0200 (EET) Received: from cooljazz.bb.dnainternet.fi (91-145-91-118.bb.dnainternet.fi [91.145.91.118]) by smtp6.welho.com (Postfix) with ESMTP id 2E3555BC00B; Tue, 4 Mar 2014 00:44:33 +0200 (EET) From: Aaro Koskinen To: Mark Brown , Liam Girdwood , Jarkko Nikula , linux-omap@vger.kernel.org, alsa-devel@alsa-project.org Cc: Peter Ujfalusi , Jarkko Nikula , Aaro Koskinen Subject: [PATCH RESEND] sound: omap: n810: fix init with DT boot Date: Tue, 4 Mar 2014 00:45:18 +0200 Message-Id: <1393886718-1817-1-git-send-email-aaro.koskinen@iki.fi> X-Mailer: git-send-email 1.9.0 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Since 3.14-rc1 only DT boot has been supported on N810, so this file fails to init. Make a minimal fix to retain functionality. This file should be properly converted to DT in longer term. There seems to be still other unresolved issues with N810 audio support, but this patch is needed at minimum as otherwise the machine driver probing would completely fail. Signed-off-by: Aaro Koskinen Acked-by: Jarkko Nikula --- Previous discussion: http://marc.info/?l=linux-omap&m=139387208426122&w=2 sound/soc/omap/n810.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sound/soc/omap/n810.c b/sound/soc/omap/n810.c index 3fde9e4..d163e18 100644 --- a/sound/soc/omap/n810.c +++ b/sound/soc/omap/n810.c @@ -305,7 +305,9 @@ static int __init n810_soc_init(void) int err; struct device *dev; - if (!(machine_is_nokia_n810() || machine_is_nokia_n810_wimax())) + if (!of_have_populated_dt() || + (!of_machine_is_compatible("nokia,n810") && + !of_machine_is_compatible("nokia,n810-wimax"))) return -ENODEV; n810_snd_device = platform_device_alloc("soc-audio", -1);