During the physical initialization of the disk, if an error occurs due to insufficient disk space, disk resize extends the database device to the largest size possible.
For example, on a server that uses 4K logical pages, if you try to increase the size of the device by 40MB, but only 39.5MB is available, the device is extended only by 39.5MB.
You cannot use disk resize to decrease the size of a device.