Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
sata_port_multipliers [2019/04/24 11:31] – [struct ata_port] rpjdaysata_port_multipliers [2019/04/24 12:30] (current) – [struct ata_device] rpjday
Line 14: Line 14:
       * Makefile       * Makefile
       * libata-pmp.c       * libata-pmp.c
 +      * libata-eh.c
  
 ===== Build files [drivers/ata] ===== ===== Build files [drivers/ata] =====
Line 108: Line 109:
         ...         ...
         ATA_FLAG_PMP            = (1 << 19), /* controller supports PMP */         ATA_FLAG_PMP            = (1 << 19), /* controller supports PMP */
 +        ...
 +</code>
 +
 +<code>
 +struct ata_port_operations {
 +        ...
 +        void (*pmp_attach)(struct ata_port *ap);
 +        void (*pmp_detach)(struct ata_port *ap);
         ...         ...
 </code> </code>
Line 172: Line 181:
         unsigned int            class;          /* ATA_DEV_xxx */         unsigned int            class;          /* ATA_DEV_xxx */
         ...         ...
 +        union {
 +                u16             id[ATA_ID_WORDS]; /* IDENTIFY xxx DEVICE data */
 +                u32             gscr[SATA_PMP_GSCR_DWORDS]; /* PMP GSCR block */
 +        } ____cacheline_aligned;
 +
 </code> </code>
  
Line 185: Line 199:
         int                     pmp;            /* port multiplier port # */         int                     pmp;            /* port multiplier port # */
         ...         ...
 +        struct ata_device       device[ATA_MAX_DEVICES];
 </code> </code>
  
Line 209: Line 224:
 </code> </code>
  
-===== libata-pmp.c =====+===== drivers/ata/ ===== 
 + 
 +==== libata-eh.c ==== 
 + 
 +<code> 
 +static int ata_eh_revalidate_and_attach(struct ata_link *link, 
 + struct ata_device **r_failed_dev) 
 +
 + struct ata_port *ap = link->ap; 
 + struct ata_eh_context *ehc = &link->eh_context; 
 + struct ata_device *dev; 
 +        ... 
 +        ata_for_each_dev(dev, link, ALL_REVERSE) { 
 +                ... 
 +                dev->class = ehc->classes[dev->devno]; 
 + 
 +                if (dev->class == ATA_DEV_PMP) 
 +                        rc = sata_pmp_attach(dev); 
 +                else 
 +                        ...    
 +</code> 
 + 
 +==== libata-pmp.c ====
  
-==== sata_pmp_configure() ====+=== sata_pmp_configure() ===
  • sata_port_multipliers.1556105488.txt.gz
  • Last modified: 2019/04/24 11:31
  • by rpjday