Commit c08fcaa9 authored by Han-Wen Nienhuys's avatar Han-Wen Nienhuys

Move notify constants.

parent 2b37e448
...@@ -285,7 +285,7 @@ func (me *MountState) writeInodeNotify(entry *raw.NotifyInvalInodeOut) Status { ...@@ -285,7 +285,7 @@ func (me *MountState) writeInodeNotify(entry *raw.NotifyInvalInodeOut) Status {
opcode: _OP_NOTIFY_INODE, opcode: _OP_NOTIFY_INODE,
}, },
handler: operationHandlers[_OP_NOTIFY_INODE], handler: operationHandlers[_OP_NOTIFY_INODE],
status: NOTIFY_INVAL_INODE, status: raw.NOTIFY_INVAL_INODE,
} }
req.outData = unsafe.Pointer(entry) req.outData = unsafe.Pointer(entry)
req.serialize() req.serialize()
...@@ -303,7 +303,7 @@ func (me *MountState) writeEntryNotify(parent uint64, name string) Status { ...@@ -303,7 +303,7 @@ func (me *MountState) writeEntryNotify(parent uint64, name string) Status {
opcode: _OP_NOTIFY_ENTRY, opcode: _OP_NOTIFY_ENTRY,
}, },
handler: operationHandlers[_OP_NOTIFY_ENTRY], handler: operationHandlers[_OP_NOTIFY_ENTRY],
status: NOTIFY_INVAL_ENTRY, status: raw.NOTIFY_INVAL_ENTRY,
} }
entry := &raw.NotifyInvalEntryOut{ entry := &raw.NotifyInvalEntryOut{
Parent: parent, Parent: parent,
......
...@@ -57,14 +57,6 @@ const ( ...@@ -57,14 +57,6 @@ const (
EROFS = Status(syscall.EROFS) EROFS = Status(syscall.EROFS)
) )
type NotifyCode int
const (
NOTIFY_POLL = -1
NOTIFY_INVAL_INODE = -2
NOTIFY_INVAL_ENTRY = -3
NOTIFY_CODE_MAX = -4
)
type Attr struct { type Attr struct {
Ino uint64 Ino uint64
......
...@@ -296,3 +296,10 @@ type NotifyInvalEntryOut struct { ...@@ -296,3 +296,10 @@ type NotifyInvalEntryOut struct {
NameLen uint32 NameLen uint32
Padding uint32 Padding uint32
} }
const (
NOTIFY_POLL = -1
NOTIFY_INVAL_INODE = -2
NOTIFY_INVAL_ENTRY = -3
NOTIFY_CODE_MAX = -4
)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment