offset, data);
 }
 
+static bool ath9k_hw_nvram_read_nvmem(struct ath_hw *ah, off_t offset,
+                                     u16 *data)
+{
+       return ath9k_hw_nvram_read_array(ah->nvmem_blob,
+                                        ah->nvmem_blob_len / sizeof(u16),
+                                        offset, data);
+}
+
 bool ath9k_hw_nvram_read(struct ath_hw *ah, u32 off, u16 *data)
 {
        struct ath_common *common = ath9k_hw_common(ah);
        struct ath9k_platform_data *pdata = ah->dev->platform_data;
        bool ret;
 
-       if (ah->eeprom_blob)
+       if (ah->nvmem_blob)
+               ret = ath9k_hw_nvram_read_nvmem(ah, off, data);
+       else if (ah->eeprom_blob)
                ret = ath9k_hw_nvram_read_firmware(ah->eeprom_blob, off, data);
        else if (pdata && !pdata->use_eeprom)
                ret = ath9k_hw_nvram_read_pdata(pdata, off, data);
 
 #include <linux/module.h>
 #include <linux/of.h>
 #include <linux/of_net.h>
+#include <linux/nvmem-consumer.h>
 #include <linux/relay.h>
 #include <linux/dmi.h>
 #include <net/ieee80211_radiotap.h>
        release_firmware(sc->sc_ah->eeprom_blob);
 }
 
+static int ath9k_nvmem_request_eeprom(struct ath_softc *sc)
+{
+       struct ath_hw *ah = sc->sc_ah;
+       struct nvmem_cell *cell;
+       void *buf;
+       size_t len;
+       int err;
+
+       cell = devm_nvmem_cell_get(sc->dev, "calibration");
+       if (IS_ERR(cell)) {
+               err = PTR_ERR(cell);
+
+               /* nvmem cell might not be defined, or the nvmem
+                * subsystem isn't included. In this case, follow
+                * the established "just return 0;" convention of
+                * ath9k_init_platform to say:
+                * "All good. Nothing to see here. Please go on."
+                */
+               if (err == -ENOENT || err == -EOPNOTSUPP)
+                       return 0;
+
+               return err;
+       }
+
+       buf = nvmem_cell_read(cell, &len);
+       if (IS_ERR(buf))
+               return PTR_ERR(buf);
+
+       /* run basic sanity checks on the returned nvram cell length.
+        * That length has to be a multiple of a "u16" (i.e.: & 1).
+        * Furthermore, it has to be more than "let's say" 512 bytes
+        * but less than the maximum of AR9300_EEPROM_SIZE (16kb).
+        */
+       if ((len & 1) == 1 || len < 512 || len >= AR9300_EEPROM_SIZE) {
+               kfree(buf);
+               return -EINVAL;
+       }
+
+       /* devres manages the calibration values release on shutdown */
+       ah->nvmem_blob = (u16 *)devm_kmemdup(sc->dev, buf, len, GFP_KERNEL);
+       kfree(buf);
+       if (IS_ERR(ah->nvmem_blob))
+               return PTR_ERR(ah->nvmem_blob);
+
+       ah->nvmem_blob_len = len;
+       ah->ah_flags &= ~AH_USE_EEPROM;
+       ah->ah_flags |= AH_NO_EEP_SWAP;
+
+       return 0;
+}
+
 static int ath9k_init_platform(struct ath_softc *sc)
 {
        struct ath9k_platform_data *pdata = sc->dev->platform_data;
        if (ret)
                return ret;
 
+       ret = ath9k_nvmem_request_eeprom(sc);
+       if (ret)
+               return ret;
+
        if (ath9k_led_active_high != -1)
                ah->config.led_active_high = ath9k_led_active_high == 1;