Commit Graph

88 Commits (348ed9e731d013c43ea857ac6a9e1330e99faaa0)

Author SHA1 Message Date
Aaron Jacobs 348ed9e731 Disabled async reads.
Allowing the kernel to send multiple reads for the same file handle
concurrently interferes with sequential read detection like that in
GoogleCloudPlatform/gcsfuse#103.
2015-08-05 11:09:20 +10:00
Aaron Jacobs 263bbab5dd Don't log errors that we expect to happen regularly.
For GoogleCloudPlatform/gcsfuse#99.
2015-08-03 13:15:29 +10:00
Aaron Jacobs 9e84136ee5 Don't run sprintf when unnecessary. 2015-07-29 15:13:22 +10:00
Aaron Jacobs 96b8ce71f0 Fixed a bug: the flags parameter is in and out. 2015-07-29 14:53:09 +10:00
Aaron Jacobs 3f954b3056 Enable async reads.
As best I can tell, this instructs the kernel not to synchronize on the
completion of a read request before sending further requests. This
definitely means further read requests, but I believe it means any sort
of request as well. It appears to make a big difference to gcsfuse read
support.
2015-07-29 14:53:09 +10:00
Aaron Jacobs 94e31a27b6 Use the fuse ID in debug logs.
It's too confusing with a distinct set of IDs for logging.
2015-07-29 14:29:31 +10:00
Aaron Jacobs c80811a735 Don't spam the everloving shit out of the console for debug logging. 2015-07-29 12:02:58 +10:00
Aaron Jacobs bbb262ee48 Read directly into out messages for files. 2015-07-29 11:02:29 +10:00
Aaron Jacobs 2e422a1305 Move where out messages are created. 2015-07-29 10:51:24 +10:00
Aaron Jacobs d903c709d3 Refactored allocation out OutMessage structs.
In preparation for allocating them up-front for ReadFile and ReadDir.
2015-07-29 10:47:41 +10:00
Aaron Jacobs 5238806cff Connection.Reply 2015-07-28 16:14:58 +10:00
Aaron Jacobs 0becfa3df2 Began fixing Connection. 2015-07-28 16:13:18 +10:00
Aaron Jacobs 3845b0f124 Use freelist.Freelist for buffer.InMessage. 2015-07-28 12:59:44 +10:00
Aaron Jacobs 9232b8275f Don't convert uint64 to interface{} for the context key every time.
This accounts for ~80% of gcsfuse allocations.
2015-07-28 12:52:38 +10:00
Aaron Jacobs c968295acd Don't spam the error logger so much. 2015-07-27 16:03:58 +10:00
Aaron Jacobs 95a6177c0c Fixed redundant internal op names. 2015-07-27 15:52:13 +10:00
Aaron Jacobs 9441e60ece Don't write zero-length replies. 2015-07-27 15:50:05 +10:00
Aaron Jacobs 3755e3c1a1 Fixed package fuse. 2015-07-27 15:43:41 +10:00
Aaron Jacobs ef3d11e2b1 It seems the write returns errors as a matter of course when unmounting. 2015-07-27 15:40:11 +10:00
Aaron Jacobs 9b9a86cf80 Fixed Connection.Reply. 2015-07-27 15:33:33 +10:00
Aaron Jacobs 448c910c13 Write some of Connection.Reply. 2015-07-27 15:21:07 +10:00
Aaron Jacobs dd1fcfedf5 Fixed more build errors. 2015-07-27 15:12:43 +10:00
Aaron Jacobs d6d4cb87c5 Fixed Connection.Init. 2015-07-27 15:10:00 +10:00
Aaron Jacobs fd0e095b3b Reimplemented ReadOp. 2015-07-27 15:08:41 +10:00
Aaron Jacobs 8c5f6d8685 Updated the ReadOp signature. 2015-07-27 14:52:35 +10:00
Aaron Jacobs 585af56849 Fixed a few more build errors. 2015-07-27 14:28:44 +10:00
Aaron Jacobs 623ae99fae Fixed a build error. 2015-07-27 14:27:34 +10:00
Aaron Jacobs 41dd5f04f5 Use a freelist for buffer.InMessage structs. 2015-07-27 13:20:28 +10:00
Aaron Jacobs a07a396c6a Added support for init ops. 2015-07-24 16:35:14 +10:00
Aaron Jacobs 6a25a1071c Connection.Init 2015-07-24 16:29:59 +10:00
Aaron Jacobs 7775584eca Killed an unnecessary field. 2015-07-24 16:23:37 +10:00
Aaron Jacobs 74e87c22b8 Killed some dead code. 2015-07-24 16:23:13 +10:00
Aaron Jacobs ba66e02af1 Fixed initFlags. 2015-07-24 16:05:01 +10:00
Aaron Jacobs 91664cfc31 Fixed maxReadahead. 2015-07-24 16:03:24 +10:00
Aaron Jacobs 2860526871 Updated newConnection. 2015-07-24 16:01:45 +10:00
Aaron Jacobs a721a505bf Document the reason for a restriction. 2015-07-24 15:35:31 +10:00
Aaron Jacobs cd47dbb4b8 Refactored fields a bit. 2015-07-24 15:32:50 +10:00
Aaron Jacobs ee2b961839 Don't depend on fuseshim.Conn for sending messages. 2015-07-24 15:31:16 +10:00
Aaron Jacobs 32418239ae Removed read locks around the device.
We require no conrrent calls to ReadOp, and that ServeOps doesn't return
until all ops have been responded to, so I believe this should be safe.
In particular, fuseshim uses the locks only to exclude reads and writes
during closing, not for anything else.
2015-07-24 15:26:07 +10:00
Aaron Jacobs 4de334e034 Fixed a bug related to EINTR. 2015-07-24 15:20:43 +10:00
Aaron Jacobs a1dadab66e Fixed a bug. 2015-07-24 15:07:55 +10:00
Aaron Jacobs 7a5761a67c Fixed some TODOs. 2015-07-24 15:05:27 +10:00
Aaron Jacobs f2e8a5d806 Connection.readMessage 2015-07-24 15:04:28 +10:00
Aaron Jacobs 3b9092aca5 Use InMessage in several places. 2015-07-24 14:33:27 +10:00
Aaron Jacobs 497407fde2 Better debug logging for getattr. 2015-07-24 12:51:32 +10:00
Aaron Jacobs 85cd1cb299 Fixed error and debug logging. 2015-07-24 12:51:32 +10:00
Aaron Jacobs 9c2f2652f7 Write replies to the kernel. 2015-07-24 12:51:32 +10:00
Aaron Jacobs b6ae9475ba Partially implemented sendReply. 2015-07-24 12:51:32 +10:00
Aaron Jacobs 9b8d9280ac Fixed a logging bug. 2015-07-24 12:51:32 +10:00
Aaron Jacobs b8d3dfd5ac Fixed statfs and interrupt. 2015-07-24 12:51:30 +10:00