ccp(4) support for AMD Ryzen 3 PRO 2200GE

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

ccp(4) support for AMD Ryzen 3 PRO 2200GE

Mark Kettenis
Linux doesn't have this yet, so this is pure guesswork, and I pulled
the name out of my ass.  But the numbers I get look random enough.

ok?

P.S. I think it would make sense to rename the device IDs and the
     strings to be similar to their companions on the chip.  I'll send
     out a separate diff for that.


Index: dev/pci/ccp_pci.c
===================================================================
RCS file: /cvs/src/sys/dev/pci/ccp_pci.c,v
retrieving revision 1.1
diff -u -p -r1.1 ccp_pci.c
--- dev/pci/ccp_pci.c 20 Apr 2018 04:37:21 -0000 1.1
+++ dev/pci/ccp_pci.c 1 May 2019 16:18:47 -0000
@@ -46,6 +46,7 @@ static const struct pci_matchid ccp_pci_
  { PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV3 },
  { PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV5A },
  { PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV5B },
+ { PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV5C },
 };
 
 int
Index: dev/pci/pcidevs
===================================================================
RCS file: /cvs/src/sys/dev/pci/pcidevs,v
retrieving revision 1.1885
diff -u -p -r1.1885 pcidevs
--- dev/pci/pcidevs 24 Apr 2019 03:44:50 -0000 1.1885
+++ dev/pci/pcidevs 1 May 2019 16:18:47 -0000
@@ -790,6 +790,7 @@ product AMD AMD64_17_1X_IOMMU 0x15d1 AMD
 product AMD AMD64_17_1X_PCIE_1 0x15d3 AMD64 17h/1xh PCIE
 product AMD AMD64_17_1X_PCIE_2 0x15db AMD64 17h/1xh PCIE
 product AMD AMD64_17_1X_PCIE_3 0x15dc AMD64 17h/1xh PCIE
+product AMD CCPV5C 0x15df Cryptographic Co-processor v5c
 product AMD AMD64_17_1X_XHCI_1 0x15e0 AMD64 17h/1xh xHCI
 product AMD AMD64_17_1X_XHCI_2 0x15e1 AMD64 17h/1xh xHCI
 product AMD RAVENRIDGE_HDA 0x15e3 Raven Ridge HD Audio
Index: dev/pci/pcidevs.h
===================================================================
RCS file: /cvs/src/sys/dev/pci/pcidevs.h,v
retrieving revision 1.1878
diff -u -p -r1.1878 pcidevs.h
--- dev/pci/pcidevs.h 24 Apr 2019 03:45:35 -0000 1.1878
+++ dev/pci/pcidevs.h 1 May 2019 16:18:47 -0000
@@ -795,6 +795,7 @@
 #define PCI_PRODUCT_AMD_AMD64_17_1X_PCIE_1 0x15d3 /* AMD64 17h/1xh PCIE */
 #define PCI_PRODUCT_AMD_AMD64_17_1X_PCIE_2 0x15db /* AMD64 17h/1xh PCIE */
 #define PCI_PRODUCT_AMD_AMD64_17_1X_PCIE_3 0x15dc /* AMD64 17h/1xh PCIE */
+#define PCI_PRODUCT_AMD_CCPV5C 0x15df /* Cryptographic Co-processor v5c */
 #define PCI_PRODUCT_AMD_AMD64_17_1X_XHCI_1 0x15e0 /* AMD64 17h/1xh xHCI */
 #define PCI_PRODUCT_AMD_AMD64_17_1X_XHCI_2 0x15e1 /* AMD64 17h/1xh xHCI */
 #define PCI_PRODUCT_AMD_RAVENRIDGE_HDA 0x15e3 /* Raven Ridge HD Audio */
Index: dev/pci/pcidevs_data.h
===================================================================
RCS file: /cvs/src/sys/dev/pci/pcidevs_data.h,v
retrieving revision 1.1873
diff -u -p -r1.1873 pcidevs_data.h
--- dev/pci/pcidevs_data.h 24 Apr 2019 03:45:35 -0000 1.1873
+++ dev/pci/pcidevs_data.h 1 May 2019 16:18:47 -0000
@@ -1512,6 +1512,10 @@ static const struct pci_known_product pc
     "AMD64 17h/1xh PCIE",
  },
  {
+    PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV5C,
+    "Cryptographic Co-processor v5c",
+ },
+ {
     PCI_VENDOR_AMD, PCI_PRODUCT_AMD_AMD64_17_1X_XHCI_1,
     "AMD64 17h/1xh xHCI",
  },

Reply | Threaded
Open this post in threaded view
|

Re: ccp(4) support for AMD Ryzen 3 PRO 2200GE

Mike Larkin-2
On Wed, May 01, 2019 at 06:26:49PM +0200, Mark Kettenis wrote:
> Linux doesn't have this yet, so this is pure guesswork, and I pulled
> the name out of my ass.  But the numbers I get look random enough.
>
> ok?
>

Sure, ok mlarkin if you didn't commit already

> P.S. I think it would make sense to rename the device IDs and the
>      strings to be similar to their companions on the chip.  I'll send
>      out a separate diff for that.
>
>
> Index: dev/pci/ccp_pci.c
> ===================================================================
> RCS file: /cvs/src/sys/dev/pci/ccp_pci.c,v
> retrieving revision 1.1
> diff -u -p -r1.1 ccp_pci.c
> --- dev/pci/ccp_pci.c 20 Apr 2018 04:37:21 -0000 1.1
> +++ dev/pci/ccp_pci.c 1 May 2019 16:18:47 -0000
> @@ -46,6 +46,7 @@ static const struct pci_matchid ccp_pci_
>   { PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV3 },
>   { PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV5A },
>   { PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV5B },
> + { PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV5C },
>  };
>  
>  int
> Index: dev/pci/pcidevs
> ===================================================================
> RCS file: /cvs/src/sys/dev/pci/pcidevs,v
> retrieving revision 1.1885
> diff -u -p -r1.1885 pcidevs
> --- dev/pci/pcidevs 24 Apr 2019 03:44:50 -0000 1.1885
> +++ dev/pci/pcidevs 1 May 2019 16:18:47 -0000
> @@ -790,6 +790,7 @@ product AMD AMD64_17_1X_IOMMU 0x15d1 AMD
>  product AMD AMD64_17_1X_PCIE_1 0x15d3 AMD64 17h/1xh PCIE
>  product AMD AMD64_17_1X_PCIE_2 0x15db AMD64 17h/1xh PCIE
>  product AMD AMD64_17_1X_PCIE_3 0x15dc AMD64 17h/1xh PCIE
> +product AMD CCPV5C 0x15df Cryptographic Co-processor v5c
>  product AMD AMD64_17_1X_XHCI_1 0x15e0 AMD64 17h/1xh xHCI
>  product AMD AMD64_17_1X_XHCI_2 0x15e1 AMD64 17h/1xh xHCI
>  product AMD RAVENRIDGE_HDA 0x15e3 Raven Ridge HD Audio
> Index: dev/pci/pcidevs.h
> ===================================================================
> RCS file: /cvs/src/sys/dev/pci/pcidevs.h,v
> retrieving revision 1.1878
> diff -u -p -r1.1878 pcidevs.h
> --- dev/pci/pcidevs.h 24 Apr 2019 03:45:35 -0000 1.1878
> +++ dev/pci/pcidevs.h 1 May 2019 16:18:47 -0000
> @@ -795,6 +795,7 @@
>  #define PCI_PRODUCT_AMD_AMD64_17_1X_PCIE_1 0x15d3 /* AMD64 17h/1xh PCIE */
>  #define PCI_PRODUCT_AMD_AMD64_17_1X_PCIE_2 0x15db /* AMD64 17h/1xh PCIE */
>  #define PCI_PRODUCT_AMD_AMD64_17_1X_PCIE_3 0x15dc /* AMD64 17h/1xh PCIE */
> +#define PCI_PRODUCT_AMD_CCPV5C 0x15df /* Cryptographic Co-processor v5c */
>  #define PCI_PRODUCT_AMD_AMD64_17_1X_XHCI_1 0x15e0 /* AMD64 17h/1xh xHCI */
>  #define PCI_PRODUCT_AMD_AMD64_17_1X_XHCI_2 0x15e1 /* AMD64 17h/1xh xHCI */
>  #define PCI_PRODUCT_AMD_RAVENRIDGE_HDA 0x15e3 /* Raven Ridge HD Audio */
> Index: dev/pci/pcidevs_data.h
> ===================================================================
> RCS file: /cvs/src/sys/dev/pci/pcidevs_data.h,v
> retrieving revision 1.1873
> diff -u -p -r1.1873 pcidevs_data.h
> --- dev/pci/pcidevs_data.h 24 Apr 2019 03:45:35 -0000 1.1873
> +++ dev/pci/pcidevs_data.h 1 May 2019 16:18:47 -0000
> @@ -1512,6 +1512,10 @@ static const struct pci_known_product pc
>      "AMD64 17h/1xh PCIE",
>   },
>   {
> +    PCI_VENDOR_AMD, PCI_PRODUCT_AMD_CCPV5C,
> +    "Cryptographic Co-processor v5c",
> + },
> + {
>      PCI_VENDOR_AMD, PCI_PRODUCT_AMD_AMD64_17_1X_XHCI_1,
>      "AMD64 17h/1xh xHCI",
>   },
>