git: d1a89bd9b6eb - main - flexspi: Stop checking for failures from malloc(M_WAITOK)
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 03 Sep 2024 10:27:12 UTC
The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=d1a89bd9b6eb1524902b619fa092c7d6de63e623 commit d1a89bd9b6eb1524902b619fa092c7d6de63e623 Author: Zhenlei Huang <zlei@FreeBSD.org> AuthorDate: 2024-09-03 10:25:27 +0000 Commit: Zhenlei Huang <zlei@FreeBSD.org> CommitDate: 2024-09-03 10:25:27 +0000 flexspi: Stop checking for failures from malloc(M_WAITOK) MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D45852 --- sys/dev/flash/flexspi/flex_spi.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/sys/dev/flash/flexspi/flex_spi.c b/sys/dev/flash/flexspi/flex_spi.c index 766a1cfaa332..9382b237ee71 100644 --- a/sys/dev/flash/flexspi/flex_spi.c +++ b/sys/dev/flash/flexspi/flex_spi.c @@ -781,12 +781,6 @@ flex_spi_attach(device_t dev) } sc->buf = malloc(sc->erasesize, SECTOR_BUFFER, M_WAITOK); - if (sc->buf == NULL) { - device_printf(sc->dev, "Unable to set up allocate internal buffer\n"); - flex_spi_detach(dev); - return (ENOMEM); - } - /* Move it to per-flash */ sc->disk = disk_alloc(); sc->disk->d_open = flex_spi_open;