dect
/
libnl
Archived
13
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
libnl/lib
roopa bc7c822f54 Add support for updating objects in the cache
This patch adds support to update a cache object during cache_include instead
of the current approach of deleting the original object and adding a new one.
This operation is conditional on the object implementing the operation. If
the update is not successful, cache_include falls back to the existing cache
inclusion process of deleting and adding the object.

It adds a new object operation called oo_update. oo_update takes two objects
as arguments, first being the existing cache object that needs update, the
second argument being the new object. Currently it is left to the implementor
to use the msg type to decide wether to delete or add the new object attributes
to the old one. But the operation type or msg type can be easily made part of the
object arguments.

The motivation for this change is explained below in the context of including
support for AF_BRIDGE objects into the link cache.

libnl today deletes an object before it includes an identical object.
But for some objects like the AF_BRIDGE objects this does not work well.
link cache uses the ifindex as its key in object searches.
If link cache were to support AF_BRIDGE family objects, todays implementation,
	- will replace the original link object with the bridge port link object
	  for add notifications
	- And a bridge port delete notification from kernel would delete the
	link object from the cache leaving the cache without the link object
	until the kernel sends another notification for that link

The bridge port link notification contains some base link object attributes
plus bridge specific protocol info attributes. In such cases we think an
operation to update the existing object in place in cache might be useful.

This can be made to work for AF_INET6 link objects too.

Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Reviewed-by: Nolan Leake <nolan@cumulusnetworks.com>
Reviewed-by: Shrijeet Mukherjee <shm@cumulusnetworks.com>
Reviewed-by: Wilson Kok <wkok@cumulusnetworks.com>
2012-11-05 13:58:50 +01:00
..
cli Support plug qdisc - queue traffic until explicit release 2012-02-14 12:02:04 +01:00
fib_lookup doc: documentation restructuring 2012-05-10 12:03:59 +02:00
genl genl/family flags can be damaged during the auto-indentation. 2012-10-19 22:16:44 +06:00
netfilter Source cleanup for upstream 2012-10-19 11:18:52 -07:00
route Set err and free ntbl when leaving neightbl_msg_parser 2012-10-29 18:16:58 +01:00
.gitignore Added lex.yy.c to .gitignore 2012-08-30 03:19:04 +06:00
Makefile.am Checkpoint before compilation attempt 2012-10-08 15:26:55 -07:00
addr.c Address comparison bug fixed 2012-08-30 21:00:39 +06:00
attr.c Fix types-related warnings based on clang diagnostics 2012-06-13 13:30:26 +02:00
cache.c Add support for updating objects in the cache 2012-11-05 13:58:50 +01:00
cache_mngr.c doc: documentation restructuring 2012-05-10 12:03:59 +02:00
cache_mngt.c doc: documentation restructuring 2012-05-10 12:03:59 +02:00
data.c Fix types-related warnings based on clang diagnostics 2012-06-13 13:30:26 +02:00
error.c Support for NLM_F_INTR 2011-07-14 10:51:49 +02:00
handlers.c doc: documentation restructuring 2012-05-10 12:03:59 +02:00
msg.c Fix types-related warnings based on clang diagnostics 2012-06-13 13:30:26 +02:00
nl.c nl_recv(): work with credentials only if "creds" given and NL_SOCK_PASSCRED set 2012-10-19 23:51:59 +06:00
object.c Add support for updating objects in the cache 2012-11-05 13:58:50 +01:00
socket.c Add missing va_end() calls 2012-10-29 18:16:58 +01:00
utils.c Fix warning "not checking return value of fscanf" in lib/utils.c: get_psched_settings 2012-08-30 03:19:04 +06:00
version.c Run-time version information is now available 2012-08-30 03:19:04 +06:00