Lines Matching refs:rid

162 wi_write_val(struct wi_softc *sc, int rid, u_int16_t val)
166 return wi_write_rid(sc, rid, &val, sizeof(val));
1703 wi_write_ssid(struct wi_softc *sc, int rid, u_int8_t *buf, int buflen)
1712 return wi_write_rid(sc, rid, &ssid, sizeof(ssid));
1994 wi_read_rid(struct wi_softc *sc, int rid, void *buf, int *buflenp)
2000 error = wi_cmd(sc, WI_CMD_ACCESS | WI_ACCESS_READ, rid, 0, 0);
2004 error = wi_read_bap(sc, rid, 0, ltbuf, sizeof(ltbuf));
2008 if (le16toh(ltbuf[1]) != rid) {
2009 device_printf(sc->sc_dev, "record read mismatch, rid=%x, got=%x\n",
2010 rid, le16toh(ltbuf[1]));
2013 len = (le16toh(ltbuf[0]) - 1) * 2; /* already got rid */
2016 "rid=%x, size=%d, len=%d\n",
2017 rid, *buflenp, len);
2021 return wi_read_bap(sc, rid, sizeof(ltbuf), buf, len);
2025 wi_write_rid(struct wi_softc *sc, int rid, void *buf, int buflen)
2030 ltbuf[0] = htole16((buflen + 1) / 2 + 1); /* includes rid */
2031 ltbuf[1] = htole16(rid);
2033 error = wi_write_bap(sc, rid, 0, ltbuf, sizeof(ltbuf));
2035 device_printf(sc->sc_dev, "%s: bap0 write failure, rid 0x%x\n",
2036 __func__, rid);
2039 error = wi_write_bap(sc, rid, sizeof(ltbuf), buf, buflen);
2041 device_printf(sc->sc_dev, "%s: bap1 write failure, rid 0x%x\n",
2042 __func__, rid);
2046 return wi_cmd(sc, WI_CMD_ACCESS | WI_ACCESS_WRITE, rid, 0, 0);
2050 wi_write_appie(struct wi_softc *sc, int rid, const struct ieee80211_appie *ie)
2060 return wi_write_rid(sc, rid, buf, ie->ie_len + sizeof(uint16_t));
2064 wi_alloc(device_t dev, int rid)
2069 sc->iobase_rid = rid;
2082 sc->mem_rid = rid;