Re: why does switch_to need three arguments?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 3 Oct 2004 08:56:21 -0400 (EDT), Rik van Riel <riel@xxxxxxxxxxx> wrote:
> On Sun, 3 Oct 2004, Jon Masters wrote:
> 
> > I do have lists of points I've spotted in several kernel books that I
> > keep planning to put online at some point - perhaps I can abuse the
> > kernelnewbies wiki for this purpose.
> 
> I would really like to see things like that in the wiki...

I'll clean up the list for Linux Kernel Development - but here's some
of it (I'm a very anal reader, who sits on trains and has a system of
corner folding according to the nature of the comments on the page.
People around me who don't know I'm crazy do certainly think it).

---- Comments on Linux Kernel Development by Robert Love ----

NOTE: These comments are transcribed from scribbles in my Zaurus while
travelling around and may require further thought and verification.

[ I like it that the book is Copyright 2004 already . ]

Page 19. The PowerPC is actually a joint venture between Apple IBM and
Motorola although this was shorted to IBM probably to save space.

Page 33. Processes should probably read process' or something.

Page 292. The terminating NULL discussion is repeated twice in these two
pages but that might be just to re-inforce the point.

Page 301. if (!ptr) should read if (!percpu_ptr). Also you seem to vary
in your use of sizeof in a few places but I think that is just style.

Page 307. Discussion of first second and third order deltas seemed to
read weirdly but I will have to think about that bit again.

I felt that the first chapter started with a lot of terminology which
might scare some people but I somehow prefer your style to that of
Understanding The Linux Kernel which is a longer reference but
potentially too long and referencey for some people.

Page 35. ``This ensures'' is written ``This ensure'' or something.

Page 42. Text inconsistent with figure  on default timeslice in 2.6.

Page 43. Missed a minus in decrementing if statement.

Page 44. wait_queue_head_t and not wake_queue_head_t.

Page 47. When a process runs out of timeslice there is a comma needed.

Chapter 4 read fine however the syscall examples could use unification.

The first sentence on page 66 does not read well.

page 11. also going over the page talks about stack size and uses old
sizes. Noticed this when flicking back at a later point.

page 74. How the interrupt number is passed in does not quite read right.

page 75. The text discussed how interrupts are handled but elsewhere in
the text it is stated that interrupt handlers sharing a line need not
all run with SA_INTERRUPT  if one does. This seems inconsistent in how
this code executes based on the first handler flags.

page 77. Disabling interrupt delivery and not deliver.

page 78. Disable all interrupt delivery and not deliver.

page 79. Disabling the line disables interrupt delivery and not deliver.

page 80. Disable local interrupt delivery and not deliver.
Enable local interrupt delivery and not deliver.
Save the current state of local interrupt delivery and not deliver.
Restore the local interrupt delivery and not deliver.

page 86. The example was going to have a problem however this is pointed
out on page 87. Still perhaps that footnote could be moved over to the
previous page.

page 89 and 92. Check names of structs.

page 99. No discussion of how work actually gets to be done and the
latencies involved.

page 99. To create the structure statically at compile time and not run
time perhaps.

page 105. Does the example not require locking when touching preempt_count.

page 37. this_rq_lock and rq_unlock perhaps should be one or the other
and its partner.

page 42. Table 3.1 has an interesting value for MAX_TIMESLICE.

page 42. Double character space between the words the and active when
swapping priori.

page 43. Based on dynami priority and not nice value perhaps here.

page 49. SCHED_FIFO and not SCHED_FF.

page 51. Five lines vertically begin or end sentences with the word process.

page 110. It is not possible to unlock a locked door after leaving
through it in reality.

page 115. A large number of processes and not large number of.

page 123. Bottom half and process context and not process context.

page 124. There is no emphasis on reinitialising existing spinlocks and
why you should only ever call init once in the whole time the lock
protected region is being used.

page 125. Bottom half and process context and not process context.

page 126. A la and not ala.

page 128. Woken up or awakened and not awakened up.

page 128. Code holding a semaphore and not spin lock can be preempted
obviously.

page 129. Dijkstra died in 2002 as is indeed pointed out so past tense
should be used.

page 131. As with semaphores should read as with spinlocks.

page 132. Completion Variable Methods and not Completion Variables Methods.

page 134. Not clear on the textual description given of seq locks in
that they double increment. Also worth mentioning that they behave just
like PowerPC hardware reservation instructions.

page 137. Need to check you really mean rmb similar to mb and not wmb.
Will ponder.

page 138. Threading example at top might break due to missing barrier
guarding b. The text is confusing issues of mutual exclusion with those
of memory sync.

page 153. We need some kind of way of hinting the unlikely nature of
that loop actually looping.

page 157. Perhaps mention the cool exponential timer distribution a bit
more fully.

page 159. Nice touch on the explanation of volatile here in order to
sync up stuff.

page 167. Need to mention what the GFP means in get free pages and tidy
up intro.

page 172. Check the allocation of user pages because they need to be
zeroed out.

page 173. GFP_ATOMIC and not GTP_ATOMIC.

page 175. Of course writing device drivers and doing DMA you will know
the difference between virtual and physical memory even if they are
mostly true statements.

page 175. Not just TLB thrashing as there might be some severe cache
contention on some architectures with which use physical index cacheing
(this statement might be a load of crap so I need to think about it).

page 177 and 179. Do you mean slack space or slab space.

page 182. The book says that on x86, pages in high memory are mapped
somewhere between the 3 and 4GB mark. This is vague and very ambiguous.

page 186-189. Repeated reference to VFS being object orientation in
disguise. WHile true in fact this point is made several times in
different ways and is a little excessive.

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux