From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752744AbdHOT3x (ORCPT ); Tue, 15 Aug 2017 15:29:53 -0400 Received: from mail-qk0-f171.google.com ([209.85.220.171]:36902 "EHLO mail-qk0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752453AbdHOT3v (ORCPT ); Tue, 15 Aug 2017 15:29:51 -0400 Subject: Re: [PATCH 2/9] ASoC: cygnus: Update bindings for audio clock changes To: Mark Brown Cc: Liam Girdwood , Rob Herring , Mark Rutland , Ray Jui , Scott Branden , Jon Mason , bcm-kernel-feedback-list@broadcom.com, Jaroslav Kysela , Takashi Iwai , alsa-devel@alsa-project.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <1502748417-26417-1-git-send-email-lori.hikichi@broadcom.com> <1502748417-26417-3-git-send-email-lori.hikichi@broadcom.com> <20170815171424.whcy4mftex6sgzgj@sirena.org.uk> From: Lori Hikichi Message-ID: Date: Tue, 15 Aug 2017 12:29:44 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <20170815171424.whcy4mftex6sgzgj@sirena.org.uk> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 8/15/2017 10:14 AM, Mark Brown wrote: > On Mon, Aug 14, 2017 at 03:06:50PM -0700, Lori Hikichi wrote: >> Allow each audio port to select which clock (if any) it wants to use. > Why is this in DT for the port and not either using standard clock > bindings to configure the clock tree or allowing the machine driver to > pick? The previous version of the driver essentially had a clock mapping that could not be changed. This is fine for 99% of our use cases. If we need to change the mapping, then we need to modify the audio port's clock mux. Creating a clock for these muxes was going to be messy. There is a mux per audio port and the registers used to program the muxes are staggered throughout the io space used by the audio driver. Additionally, these registers have bits that are controlled by the audio driver. Had I used syscon to access these registers this would have resulted in a very fragmented io space, complicating the audio drivers access this space. I have put the mux assignment in DT because the assignment is a static property and did not need run time programmability from the machine driver. Lori.