diff --git a/config.h b/config.h index 073eae0..af3eb1f 100644 --- a/config.h +++ b/config.h @@ -206,6 +206,8 @@ #define HAVE_FSYNC 1 +#define WITH_OHOS 1 + /* Define to `__inline__' or `__inline' if that's what the C compiler calls it, or to nothing if 'inline' is not supported under any name. */ #ifndef __cplusplus diff --git a/fsck/fsck.c b/fsck/fsck.c index f0ee9f9..edc1b6d 100644 --- a/fsck/fsck.c +++ b/fsck/fsck.c @@ -3335,7 +3335,7 @@ int fsck_verify(struct f2fs_sb_info *sbi) c.bug_on = 1; } -#ifndef WITH_ANDROID +#ifndef WITH_OHOS if (nr_unref_nid && !c.ro) { char ans[255] = {0}; int res; diff --git a/lib/libf2fs.c b/lib/libf2fs.c index 115208c..148ed3d 100644 --- a/lib/libf2fs.c +++ b/lib/libf2fs.c @@ -897,7 +897,7 @@ int get_device_info(int i) #ifdef HDIO_GETGIO struct hd_geometry geom; #endif -#if !defined(WITH_ANDROID) && defined(__linux__) +#if !defined(WITH_OHOS) && defined(__linux__) sg_io_hdr_t io_hdr; unsigned char reply_buffer[96] = {0}; unsigned char model_inq[6] = {MODELINQUIRY}; @@ -999,7 +999,7 @@ int get_device_info(int i) #endif } -#if !defined(WITH_ANDROID) && defined(__linux__) +#if !defined(WITH_OHOS) && defined(__linux__) /* Send INQUIRY command */ memset(&io_hdr, 0, sizeof(sg_io_hdr_t)); io_hdr.interface_id = 'S';