diff options
-rw-r--r-- | hurd/libstore/copy_store.mdwn | 13 | ||||
-rw-r--r-- | hurd/libstore/zero_store.mdwn | 9 |
2 files changed, 20 insertions, 2 deletions
diff --git a/hurd/libstore/copy_store.mdwn b/hurd/libstore/copy_store.mdwn index 808470ec..c0a25d7d 100644 --- a/hurd/libstore/copy_store.mdwn +++ b/hurd/libstore/copy_store.mdwn @@ -1,4 +1,4 @@ -[[!meta copyright="Copyright © 2007, 2008, 2009 Free Software Foundation, +[[!meta copyright="Copyright © 2000, 2007, 2008, 2009 Free Software Foundation, Inc."]] [[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable @@ -10,3 +10,14 @@ is included in the section entitled [[GNU Free Documentation License|/fdl]]."]]"""]] [[!meta title="copy store: copy-on-write; discard changes on termination"]] + +A *copy* store is meaningful only with respect to a child store. What a *copy* +store does is to read the child store's entire contents into memory at startup +time and then use that buffer as the contents of the store thereafter. (The +code for this is in `libstore/copy.c`.) + +Because of how the interfaces are specified, reading the entire contents of a +[[*zero* store|zero store]] in fact means just `vm_allocate`ing fresh memory. +So, a *copy* store based on a [[*zero* store|zero store]] is just what you'd +get from `vm_allocate`ing some memory and passing it into +`store_buffer_create`. diff --git a/hurd/libstore/zero_store.mdwn b/hurd/libstore/zero_store.mdwn index 120847ba..4c53ab56 100644 --- a/hurd/libstore/zero_store.mdwn +++ b/hurd/libstore/zero_store.mdwn @@ -1,4 +1,4 @@ -[[!meta copyright="Copyright © 2007, 2008, 2009 Free Software Foundation, +[[!meta copyright="Copyright © 2000, 2007, 2008, 2009 Free Software Foundation, Inc."]] [[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable @@ -10,3 +10,10 @@ is included in the section entitled [[GNU Free Documentation License|/fdl]]."]]"""]] [[!meta title="zero store: empty block device"]] + +A *zero* store is what `/dev/zero` is (always reads zeros), the setting on +`/dev/zero` gives no name (i.e. size) and the default size is the maximum +possible. The only meaning of the size of a *zero* is what `st_size` will +report and what offsets it will let you try to read or write from--there is +never any data associated with a *zero* store. (The code for this is in +`libstore/zero.c`.) |