Merge tag 'folio-5.18d' of git://git.infradead.org/users/willy/pagecache
[linux-2.6-microblaze.git] / arch / um / drivers / ubd_kern.c
index 69d2d00..b03269f 100644 (file)
@@ -1526,13 +1526,19 @@ static void do_io(struct io_thread_req *req, struct io_desc *desc)
                        }
                        break;
                case REQ_OP_DISCARD:
-               case REQ_OP_WRITE_ZEROES:
                        n = os_falloc_punch(req->fds[bit], off, len);
                        if (n) {
                                req->error = map_error(-n);
                                return;
                        }
                        break;
+               case REQ_OP_WRITE_ZEROES:
+                       n = os_falloc_zeroes(req->fds[bit], off, len);
+                       if (n) {
+                               req->error = map_error(-n);
+                               return;
+                       }
+                       break;
                default:
                        WARN_ON_ONCE(1);
                        req->error = BLK_STS_NOTSUPP;