Lines Matching refs:hwcaps

2237 static int spi_nor_hwcaps2cmd(u32 hwcaps, const int table[][2], size_t size)  in spi_nor_hwcaps2cmd()  argument
2242 if (table[i][0] == (int)hwcaps) in spi_nor_hwcaps2cmd()
2248 int spi_nor_hwcaps_read2cmd(u32 hwcaps) in spi_nor_hwcaps_read2cmd() argument
2269 return spi_nor_hwcaps2cmd(hwcaps, hwcaps_read2cmd, in spi_nor_hwcaps_read2cmd()
2273 int spi_nor_hwcaps_pp2cmd(u32 hwcaps) in spi_nor_hwcaps_pp2cmd() argument
2286 return spi_nor_hwcaps2cmd(hwcaps, hwcaps_pp2cmd, in spi_nor_hwcaps_pp2cmd()
2371 spi_nor_spimem_adjust_hwcaps(struct spi_nor *nor, u32 *hwcaps) in spi_nor_spimem_adjust_hwcaps() argument
2377 *hwcaps &= ~SNOR_HWCAPS_X_X_X; in spi_nor_spimem_adjust_hwcaps()
2384 *hwcaps &= ~(SNOR_HWCAPS_X_X_X | SNOR_HWCAPS_X_X_X_DTR); in spi_nor_spimem_adjust_hwcaps()
2386 for (cap = 0; cap < sizeof(*hwcaps) * BITS_PER_BYTE; cap++) { in spi_nor_spimem_adjust_hwcaps()
2389 if (!(*hwcaps & BIT(cap))) in spi_nor_spimem_adjust_hwcaps()
2395 *hwcaps &= ~BIT(cap); in spi_nor_spimem_adjust_hwcaps()
2403 *hwcaps &= ~BIT(cap); in spi_nor_spimem_adjust_hwcaps()
2630 const struct spi_nor_hwcaps *hwcaps) in spi_nor_default_setup() argument
2640 shared_mask = hwcaps->mask & params->hwcaps.mask; in spi_nor_default_setup()
2734 const struct spi_nor_hwcaps *hwcaps) in spi_nor_setup() argument
2739 ret = nor->params->setup(nor, hwcaps); in spi_nor_setup()
2741 ret = spi_nor_default_setup(nor, hwcaps); in spi_nor_setup()
2780 params->hwcaps.mask |= SNOR_HWCAPS_READ_1_1_2; in spi_nor_no_sfdp_init_params()
2787 params->hwcaps.mask |= SNOR_HWCAPS_READ_1_1_4; in spi_nor_no_sfdp_init_params()
2794 params->hwcaps.mask |= SNOR_HWCAPS_READ_1_1_8; in spi_nor_no_sfdp_init_params()
2801 params->hwcaps.mask |= SNOR_HWCAPS_READ_8_8_8_DTR; in spi_nor_no_sfdp_init_params()
2808 params->hwcaps.mask |= SNOR_HWCAPS_PP_8_8_8_DTR; in spi_nor_no_sfdp_init_params()
3010 params->hwcaps.mask |= SNOR_HWCAPS_READ_FAST; in spi_nor_init_default_params()
3014 params->hwcaps.mask &= ~SNOR_HWCAPS_READ_FAST; in spi_nor_init_default_params()
3018 params->hwcaps.mask |= SNOR_HWCAPS_READ; in spi_nor_init_default_params()
3023 if (params->hwcaps.mask & SNOR_HWCAPS_READ_FAST) in spi_nor_init_default_params()
3028 params->hwcaps.mask |= SNOR_HWCAPS_PP; in spi_nor_init_default_params()
3033 params->hwcaps.mask |= SNOR_HWCAPS_PP_1_1_4; in spi_nor_init_default_params()
3466 const struct spi_nor_hwcaps *hwcaps) in spi_nor_scan() argument
3524 ret = spi_nor_setup(nor, hwcaps); in spi_nor_scan()
3628 const struct spi_nor_hwcaps hwcaps = { .mask = SNOR_HWCAPS_ALL }; in spi_nor_probe() local
3661 ret = spi_nor_scan(nor, flash_name, &hwcaps); in spi_nor_probe()