~ubuntu-branches/ubuntu/quantal/linux-lowlatency/quantal-proposed

« back to all changes in this revision

Viewing changes to include/linux/net.h

  • Committer: Package Import Robot
  • Author(s): Andy Whitcroft, Andy Whitcroft
  • Date: 2012-06-21 09:16:38 UTC
  • Revision ID: package-import@ubuntu.com-20120621091638-gubhv4nox8xez1ct
Tags: 3.5.0-1.1
[ Andy Whitcroft]

* Rebuild lowlatency against Ubuntu-3.5.0-1.1
* All new configuration system to allow configuration deltas to be
  exposed via debian.lowlatency/config-delta

Show diffs side-by-side

added added

removed removed

Lines of Context:
206
206
                                      int offset, size_t size, int flags);
207
207
        ssize_t         (*splice_read)(struct socket *sock,  loff_t *ppos,
208
208
                                       struct pipe_inode_info *pipe, size_t len, unsigned int flags);
 
209
        void            (*set_peek_off)(struct sock *sk, int val);
209
210
};
210
211
 
211
212
#define DECLARE_SOCKADDR(type, dst, src)        \
249
250
#define              sockfd_put(sock) fput(sock->file)
250
251
extern int           net_ratelimit(void);
251
252
 
 
253
#define net_ratelimited_function(function, ...)                 \
 
254
do {                                                            \
 
255
        if (net_ratelimit())                                    \
 
256
                function(__VA_ARGS__);                          \
 
257
} while (0)
 
258
 
 
259
#define net_emerg_ratelimited(fmt, ...)                         \
 
260
        net_ratelimited_function(pr_emerg, fmt, ##__VA_ARGS__)
 
261
#define net_alert_ratelimited(fmt, ...)                         \
 
262
        net_ratelimited_function(pr_alert, fmt, ##__VA_ARGS__)
 
263
#define net_crit_ratelimited(fmt, ...)                          \
 
264
        net_ratelimited_function(pr_crit, fmt, ##__VA_ARGS__)
 
265
#define net_err_ratelimited(fmt, ...)                           \
 
266
        net_ratelimited_function(pr_err, fmt, ##__VA_ARGS__)
 
267
#define net_notice_ratelimited(fmt, ...)                        \
 
268
        net_ratelimited_function(pr_notice, fmt, ##__VA_ARGS__)
 
269
#define net_warn_ratelimited(fmt, ...)                          \
 
270
        net_ratelimited_function(pr_warn, fmt, ##__VA_ARGS__)
 
271
#define net_info_ratelimited(fmt, ...)                          \
 
272
        net_ratelimited_function(pr_info, fmt, ##__VA_ARGS__)
 
273
#define net_dbg_ratelimited(fmt, ...)                           \
 
274
        net_ratelimited_function(pr_debug, fmt, ##__VA_ARGS__)
 
275
 
252
276
#define net_random()            random32()
253
277
#define net_srandom(seed)       srandom32((__force u32)seed)
254
278
 
289
313
        MODULE_ALIAS("net-pf-" __stringify(pf) "-proto-" __stringify(proto) \
290
314
                     "-type-" __stringify(type))
291
315
 
 
316
#define MODULE_ALIAS_NET_PF_PROTO_NAME(pf, proto, name) \
 
317
        MODULE_ALIAS("net-pf-" __stringify(pf) "-proto-" __stringify(proto) \
 
318
                     name)
292
319
#endif /* __KERNEL__ */
293
320
#endif  /* _LINUX_NET_H */