Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753695AbbBZMzp (ORCPT ); Thu, 26 Feb 2015 07:55:45 -0500 Received: from cantor2.suse.de ([195.135.220.15]:38594 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751216AbbBZMzn (ORCPT ); Thu, 26 Feb 2015 07:55:43 -0500 Message-ID: <54EF17CB.7070803@suse.de> Date: Thu, 26 Feb 2015 13:55:39 +0100 From: Alexander Graf User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: "J. German Rivera" , gregkh@linuxfoundation.org, arnd@arndb.de, linux-kernel@vger.kernel.org CC: stuart.yoder@freescale.com, Kim.Phillips@freescale.com, scottwood@freescale.com, bhamciu1@freescale.com, R89243@freescale.com, Geoff.Thorpe@freescale.com, bhupesh.sharma@freescale.com, nir.erez@freescale.com, richard.schmitt@freescale.com Subject: Re: [PATCH v7 1/3] drivers/bus: Added Freescale Management Complex APIs References: <1424816514-26369-1-git-send-email-German.Rivera@freescale.com> <1424816514-26369-2-git-send-email-German.Rivera@freescale.com> In-Reply-To: <1424816514-26369-2-git-send-email-German.Rivera@freescale.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2243 Lines: 74 On 24.02.15 23:21, J. German Rivera wrote: > APIs to access the Management Complex (MC) hardware > module of Freescale LS2 SoCs. This patch includes > APIs to check the MC firmware version and to manipulate > DPRC objects in the MC. > > Signed-off-by: J. German Rivera > Signed-off-by: Stuart Yoder Only 2 minor nits. [...] > +int mc_get_version(struct fsl_mc_io *mc_io, struct mc_version *mc_ver_info) > +{ > + struct mc_command cmd = { 0 }; > + int err; > + > + /* prepare command */ > + cmd.header = mc_encode_cmd_header(DPMNG_CMDID_GET_VERSION, > + MC_CMD_PRI_LOW, 0); > + > + /* send command to mc*/ Either my mail client is broken or this is a copy&paste error throughout the file :). > + err = mc_send_command(mc_io, &cmd); > + if (err) > + return err; > + > + /* retrieve response parameters */ > + mc_ver_info->revision = mc_dec(cmd.params[0], 0, 32); > + mc_ver_info->major = mc_dec(cmd.params[0], 32, 32); > + mc_ver_info->minor = mc_dec(cmd.params[1], 0, 32); > + > + return 0; > +} [...] > + > +struct mc_command { > + uint64_t header; > + uint64_t params[MC_CMD_NUM_OF_PARAMS]; > +}; > + > +enum mc_cmd_status { > + MC_CMD_STATUS_OK = 0x0, /*!< Completed successfully */ What is /*!< supposed to be? Can't this just be /*? > + MC_CMD_STATUS_READY = 0x1, /*!< Ready to be processed */ > + MC_CMD_STATUS_AUTH_ERR = 0x3, /*!< Authentication error */ > + MC_CMD_STATUS_NO_PRIVILEGE = 0x4, /*!< No privilege */ > + MC_CMD_STATUS_DMA_ERR = 0x5, /*!< DMA or I/O error */ > + MC_CMD_STATUS_CONFIG_ERR = 0x6, /*!< Configuration error */ > + MC_CMD_STATUS_TIMEOUT = 0x7, /*!< Operation timed out */ > + MC_CMD_STATUS_NO_RESOURCE = 0x8, /*!< No resources */ > + MC_CMD_STATUS_NO_MEMORY = 0x9, /*!< No memory available */ > + MC_CMD_STATUS_BUSY = 0xA, /*!< Device is busy */ > + MC_CMD_STATUS_UNSUPPORTED_OP = 0xB, /*!< Unsupported operation */ > + MC_CMD_STATUS_INVALID_STATE = 0xC /*!< Invalid state */ > +}; Alex -- 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/