View | Details | Raw Unified
Collapse All | Expand All

(-) 1.40/net/bluetooth/af_bluetooth.c (-3 / +3 lines)
 Lines 62-68    Link Here 
int bt_sock_register(int proto, struct net_proto_family *ops)
int bt_sock_register(int proto, struct net_proto_family *ops)
{
{
	if (proto >= BT_MAX_PROTO)
	if (proto < 0 || proto >= BT_MAX_PROTO)
		return -EINVAL;
		return -EINVAL;
	if (bt_proto[proto])
	if (bt_proto[proto])
 Lines 75-81    Link Here 
int bt_sock_unregister(int proto)
int bt_sock_unregister(int proto)
{
{
	if (proto >= BT_MAX_PROTO)
	if (proto < 0 || proto >= BT_MAX_PROTO)
		return -EINVAL;
		return -EINVAL;
	if (!bt_proto[proto])
	if (!bt_proto[proto])
 Lines 90-96    Link Here 
{
{
	int err = 0;
	int err = 0;
	if (proto >= BT_MAX_PROTO)
	if (proto < 0 || proto >= BT_MAX_PROTO)
		return -EINVAL;
		return -EINVAL;
#if defined(CONFIG_KMOD)
#if defined(CONFIG_KMOD)