北邮的滑动窗口协议 C源代码清单 int tcp mem schedule struct sock sk int size int kind { int amt TCP PAGES size ; sk >forward alloc + amt TCP MEM QUANTUM; atomic add amt &tcp memory allocated ; Under limit if atomic read &tcp memory allocated < sysctl tcp mem[0