--- zzzz-none-000/linux-4.9.276/drivers/misc/eeprom/at24.c 2021-07-20 14:21:16.000000000 +0000 +++ falcon-5530-750/linux-4.9.276/drivers/misc/eeprom/at24.c 2023-04-05 08:19:01.000000000 +0000 @@ -580,6 +580,8 @@ if (node) { if (of_get_property(node, "read-only", NULL)) chip->flags |= AT24_FLAG_READONLY; + if (of_get_property(node, "avm,no-test", NULL)) + chip->flags |= AT24_FLAG_NOTEST; val = of_get_property(node, "pagesize", NULL); if (val) chip->page_size = be32_to_cpup(val); @@ -764,14 +766,16 @@ i2c_set_clientdata(client, at24); - /* - * Perform a one-byte test read to verify that the - * chip is functional. - */ - err = at24_read(at24, 0, &test_byte, 1); - if (err) { - err = -ENODEV; - goto err_clients; + if (!(chip.flags & AT24_FLAG_NOTEST)) { + /* + * Perform a one-byte test read to verify that the + * chip is functional. + */ + err = at24_read(at24, 0, &test_byte, 1); + if (err) { + err = -ENODEV; + goto err_clients; + } } at24->nvmem_config.name = dev_name(&client->dev);