diff --git a/tools/p2a.cpp b/tools/p2a.cpp
index db8b75d..3cd641a 100644
--- a/tools/p2a.cpp
+++ b/tools/p2a.cpp
@@ -29,6 +29,7 @@
 #include <cstdint>
 #include <cstring>
 #include <memory>
+#include <span>
 #include <string>
 
 namespace host_tool
@@ -105,8 +106,8 @@
         bytesRead = sys->read(*inputFd, readBuffer.data(), readBuffer.size());
         if (bytesRead > 0)
         {
-            bridge->write(stdplus::span<const std::uint8_t>(readBuffer.data(),
-                                                            bytesRead));
+            bridge->write(
+                std::span<const std::uint8_t>(readBuffer.data(), bytesRead));
 
             /* Ok, so the data is staged, now send the blob write with the
              * details.
diff --git a/tools/pci.cpp b/tools/pci.cpp
index 150095f..8403771 100644
--- a/tools/pci.cpp
+++ b/tools/pci.cpp
@@ -30,6 +30,7 @@
 #include <stdplus/handle/managed.hpp>
 
 #include <cstring>
+#include <span>
 #include <system_error>
 
 namespace host_tool
@@ -104,7 +105,7 @@
     }
 }
 
-void PciAccessBridge::write(const stdplus::span<const std::uint8_t> data)
+void PciAccessBridge::write(const std::span<const std::uint8_t> data)
 {
     if (data.size() > dataLength)
     {
diff --git a/tools/pci.hpp b/tools/pci.hpp
index 33878c8..8f40910 100644
--- a/tools/pci.hpp
+++ b/tools/pci.hpp
@@ -22,7 +22,7 @@
 
 #include <linux/pci_regs.h>
 
-#include <stdplus/types.hpp>
+#include <span>
 
 // Some versions of the linux/pci_regs.h header don't define this
 #ifndef PCI_STD_NUM_BARS
@@ -37,7 +37,7 @@
   public:
     virtual ~PciBridgeIntf() = default;
 
-    virtual void write(const stdplus::span<const std::uint8_t> data) = 0;
+    virtual void write(const std::span<const std::uint8_t> data) = 0;
     virtual void configure(const ipmi_flash::PciConfigResponse& config) = 0;
 
     virtual std::size_t getDataLength() = 0;
@@ -48,7 +48,7 @@
   public:
     virtual ~PciAccessBridge();
 
-    virtual void write(const stdplus::span<const std::uint8_t> data) override;
+    virtual void write(const std::span<const std::uint8_t> data) override;
     virtual void configure(const ipmi_flash::PciConfigResponse&) override{};
 
     std::size_t getDataLength() override
diff --git a/tools/test/tools_pci_unittest.cpp b/tools/test/tools_pci_unittest.cpp
index ca6b7ab..c3ce610 100644
--- a/tools/test/tools_pci_unittest.cpp
+++ b/tools/test/tools_pci_unittest.cpp
@@ -23,6 +23,7 @@
 
 #include <algorithm>
 #include <cstdlib>
+#include <span>
 #include <string>
 #include <vector>
 
@@ -350,8 +351,7 @@
     expectSetup(pciMock, dev, &nuvotonDevice, region.data());
 
     std::unique_ptr<PciBridgeIntf> bridge = nuvotonDevice.getBridge(&pciMock);
-    EXPECT_THROW(bridge->write(stdplus::span<std::uint8_t>(data)),
-                 ToolException);
+    EXPECT_THROW(bridge->write(std::span<std::uint8_t>(data)), ToolException);
 }
 
 TEST(NuvotonWriteTest, Success)
@@ -366,10 +366,10 @@
     expectSetup(pciMock, dev, &nuvotonDevice, region.data());
 
     std::unique_ptr<PciBridgeIntf> bridge = nuvotonDevice.getBridge(&pciMock);
-    bridge->write(stdplus::span<std::uint8_t>(data));
+    bridge->write(std::span<std::uint8_t>(data));
 
-    EXPECT_THAT(stdplus::span<uint8_t>(&region[0], data.size()),
-                SpanEq(stdplus::span<uint8_t>(data)));
+    EXPECT_THAT(std::span<uint8_t>(&region[0], data.size()),
+                SpanEq(std::span<uint8_t>(data)));
 }
 
 TEST(NuvotonConfigureTest, Success)
@@ -592,8 +592,7 @@
     expectSetup(pciMock, dev, &aspeedDevice, region.data());
 
     std::unique_ptr<PciBridgeIntf> bridge = aspeedDevice.getBridge(&pciMock);
-    EXPECT_THROW(bridge->write(stdplus::span<std::uint8_t>(data)),
-                 ToolException);
+    EXPECT_THROW(bridge->write(std::span<std::uint8_t>(data)), ToolException);
 }
 
 TEST(AspeedWriteTest, Success)
@@ -608,10 +607,10 @@
     expectSetup(pciMock, dev, &aspeedDevice, region.data());
 
     std::unique_ptr<PciBridgeIntf> bridge = aspeedDevice.getBridge(&pciMock);
-    bridge->write(stdplus::span<std::uint8_t>(data));
+    bridge->write(std::span<std::uint8_t>(data));
 
-    EXPECT_THAT(stdplus::span<uint8_t>(&region[0x10000], data.size()),
-                SpanEq(stdplus::span<uint8_t>(data)));
+    EXPECT_THAT(std::span<uint8_t>(&region[0x10000], data.size()),
+                SpanEq(std::span<uint8_t>(data)));
 }
 
 TEST(AspeedConfigureTest, Success)
@@ -628,7 +627,7 @@
 
     auto configSpan = stdplus::raw::asSpan<uint8_t>(config);
     EXPECT_THAT(
-        stdplus::span<uint8_t>(&region[AspeedDevice::bridge], sizeof(config)),
+        std::span<uint8_t>(&region[AspeedDevice::bridge], sizeof(config)),
         SpanEq(configSpan));
 }
 
