Config
| 342 | |
| 343 | // Config |
| 344 | __attribute__((always_inline)) inline void SetMemoryPageSize(uint32_t size){ |
| 345 | assert(size >= GetMinMemoryPageSize() && size <= GetMaxMemoryPageSize()); |
| 346 | |
| 347 | uint32_t i = 0; |
| 348 | while(!(size & 1)) { |
| 349 | i++; |
| 350 | size >>= 1; |
| 351 | } |
| 352 | |
| 353 | assert(i >= 12); |
| 354 | cRegs->config = (cRegs->config & ~NVME_CFG_MPS(NVME_CFG_MPS_MASK)) | NVME_CFG_MPS(i - 12); // Host memory page size (2 ^ (12 + MPSMIN)) |
| 355 | } |
| 356 | |
| 357 | __attribute__((always_inline)) inline void SetCommandSet(uint8_t set){ |
| 358 | cRegs->config = (cRegs->config & ~NVME_CFG_CSS(NVME_CFG_CSS_MASK)) | NVME_CFG_CSS(set); |
nothing calls this directly
no outgoing calls
no test coverage detected