Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756308AbbGGBgJ (ORCPT ); Mon, 6 Jul 2015 21:36:09 -0400 Received: from muin.pair.com ([209.68.1.55]:63464 "EHLO muin.pair.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755844AbbGGBgD convert rfc822-to-8bit (ORCPT ); Mon, 6 Jul 2015 21:36:03 -0400 References: In-Reply-To: Mime-Version: 1.0 (Apple Message framework v1085) Content-Type: text/plain; charset=us-ascii Message-Id: Content-Transfer-Encoding: 8BIT Cc: , , , , , , , From: Timur Tabi Subject: Re: [alsa-devel][PATCH 1/2] ASoC: fsl_ssi: Add driver suspend and resume to support MEGA Fast Date: Mon, 6 Jul 2015 21:36:02 -0400 To: Zidan Wang X-Mailer: Apple Mail (2.1085) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1143 Lines: 40 On Jul 6, 2015, at 4:49 AM, Zidan Wang wrote: > +static bool fsl_ssi_readable_reg(struct device *dev, unsigned int reg) > +{ > + switch (reg) { > + case CCSR_SSI_STX0: > + case CCSR_SSI_STX1: > + case CCSR_SSI_SRX0: > + case CCSR_SSI_SRX1: > + case CCSR_SSI_SCR: > + case CCSR_SSI_SISR: > + case CCSR_SSI_SIER: > + case CCSR_SSI_STCR: > + case CCSR_SSI_SRCR: > + case CCSR_SSI_STCCR: > + case CCSR_SSI_SRCCR: > + case CCSR_SSI_SFCSR: > + case CCSR_SSI_STR: > + case CCSR_SSI_SOR: > + case CCSR_SSI_SACNT: > + case CCSR_SSI_SACADD: > + case CCSR_SSI_SACDAT: > + case CCSR_SSI_SATAG: > + case CCSR_SSI_STMSK: > + case CCSR_SSI_SRMSK: > + case CCSR_SSI_SACCST: > + case CCSR_SSI_SACCEN: > + case CCSR_SSI_SACCDIS: > + return true; > + default: > + return false; > + } > +} This should be the other way around: return true by default, and false it is one of the few registers that is not readable.-- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/