gtp: do not allow adding duplicate tid and ms_addr pdp context
authorTaehee Yoo <ap420073@gmail.com>
Wed, 11 Dec 2019 08:23:00 +0000 (08:23 +0000)
committerJakub Kicinski <jakub.kicinski@netronome.com>
Sun, 15 Dec 2019 01:15:24 +0000 (17:15 -0800)
commit6b01b1d9b2d38dc84ac398bfe9f00baff06a31e5
tree1a53bd7f1d76c70728e9038c8e491db2f34da683
parent5d485ed88d48f8101a2067348e267c0aaf4ed486
gtp: do not allow adding duplicate tid and ms_addr pdp context

GTP RX packet path lookups pdp context with TID. If duplicate TID pdp
contexts are existing in the list, it couldn't select correct pdp context.
So, TID value  should be unique.
GTP TX packet path lookups pdp context with ms_addr. If duplicate ms_addr pdp
contexts are existing in the list, it couldn't select correct pdp context.
So, ms_addr value should be unique.

Fixes: 459aa660eb1d ("gtp: add initial driver for datapath of GPRS Tunneling Protocol (GTP-U)")
Signed-off-by: Taehee Yoo <ap420073@gmail.com>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
drivers/net/gtp.c