lkml.org 
[lkml]   [2014]   [Jul]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v11 3/8] ata: libahci_platform: move port_map parameters into the AHCI structure
A couple nit picks.

On Thu, Jul 24, 2014 at 11:17:25AM +0200, Antoine Ténart wrote:
> @@ -321,6 +321,8 @@ struct ahci_host_priv {
> u32 cap; /* cap to use */
> u32 cap2; /* cap2 to use */
> u32 port_map; /* port map to use */
> + u32 force_port_map; /* force port map */
> + u32 mask_port_map; /* mask out particular bits */

Let's collect the inputs, including flags, at the top and mark them clearly.

> int ahci_platform_init_host(struct platform_device *pdev,
> struct ahci_host_priv *hpriv,
> const struct ata_port_info *pi_template,
> - unsigned long host_flags,
> - unsigned int force_port_map,
> - unsigned int mask_port_map)
> + unsigned long host_flags)

This doesn't make much sense to me. Near the head of the function, it
does

hpriv->flags |= host_flags;

Wouldn't it make more sense to just let the caller set hpriv->flags?

Thanks.

--
tejun
--
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/

\
 
 \ /
  Last update: 2014-07-29 17:21    [W:0.134 / U:6.712 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site