2 * This file is open source software, licensed to you under the terms
3 * of the Apache License, Version 2.0 (the "License"). See the NOTICE file
4 * distributed with this work for additional information regarding copyright
5 * ownership. You may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing,
12 * software distributed under the License is distributed on an
13 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14 * KIND, either express or implied. See the License for the
15 * specific language governing permissions and limitations
19 * Copyright (C) 2022 ScyllaDB.
24 #include <linux/magic.h>
28 #ifndef XFS_SUPER_MAGIC
29 #define XFS_SUPER_MAGIC 0x58465342
32 #ifndef EXT2_SUPER_MAGIC
33 #define EXT2_SUPER_MAGIC 0xEF53
36 #ifndef EXT3_SUPER_MAGIC
37 #define EXT3_SUPER_MAGIC 0xEF53
40 #ifndef EXT4_SUPER_MAGIC
41 #define EXT4_SUPER_MAGIC 0xEF53
44 #ifndef NFS_SUPER_MAGIC
45 #define NFS_SUPER_MAGIC 0x6969
49 #define TMPFS_MAGIC 0x01021994
52 #ifndef FUSE_SUPER_MAGIC
53 #define FUSE_SUPER_MAGIC 0x65735546
56 #ifndef BTRFS_SUPER_MAGIC
57 #define BTRFS_SUPER_MAGIC 0x9123683E
60 #ifndef HFS_SUPER_MAGIC
61 #define HFS_SUPER_MAGIC 0x4244
68 static constexpr unsigned long xfs = XFS_SUPER_MAGIC;
69 static constexpr unsigned long ext2 = EXT2_SUPER_MAGIC;
70 static constexpr unsigned long ext3 = EXT3_SUPER_MAGIC;
71 static constexpr unsigned long ext4 = EXT4_SUPER_MAGIC;
72 static constexpr unsigned long nfs = NFS_SUPER_MAGIC;
73 static constexpr unsigned long tmpfs = TMPFS_MAGIC;
74 static constexpr unsigned long fuse = FUSE_SUPER_MAGIC;
75 static constexpr unsigned long btrfs = BTRFS_SUPER_MAGIC;
76 static constexpr unsigned long hfs = HFS_SUPER_MAGIC;
79 } // internal namespace
81 } // seastar namespace