Re: [PATCH] ahci: separate port number determination from host initialization

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Tejun Heo wrote:
ahci used to reset controller then fetch cap value to be used for
configuration.  On some controller this misses some cap bits and ahci
got modified to maintain cap and ports_impl values over reset, so
there is no reason to reset the controller before fetching those
register values.

Separate out ahci_determine_nr_ports() from ahci_host_init() and it
before starting to initialize probe_ent.  This makes ahci's init_one
more consistent to other drivers and eases conversion to new init
model.

Also, the initialization is more robust as it doesn't depend on
ports_impl being writeable when HONOR_PI is set but the register
itself is zero.

Tested on ICH7 (no ports_impl) and 8 AHCI (w/ ports_impl).

Signed-off-by: Tejun Heo <htejun@xxxxxxxxx>

I would rather make things explicit by creating an ahci_read_bios_config() function, and associated data structures, which reads all register values that are not preserved across reset. This would also be the code point at which we would handle a no-BIOS/uninitialized configuration.

After such a change, this patch will look smaller and nicer.

	Jeff



-
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux