01 Dec, 2011
1 commit
-
Enrolling CAIF link layers are refactored.
Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller
04 Oct, 2011
1 commit
-
The allocation of "phyinfo" wasn't checked, and also the allocation
wasn't freed on error paths. Sjur Brændeland pointed out as well
that "phy_driver" should be freed on the error path too.Signed-off-by: Dan Carpenter
Acked-by: Sjur Brændeland
Signed-off-by: David S. Miller
29 Aug, 2011
1 commit
-
Remove per site OOM messages because they duplicate
the generic mm subsystem OOM message.Use kzalloc instead of kmalloc/memset
when next to the OOM message removals.Reduces object size (allyesconfig ~2%)
$ size -t drivers/net/caif/built-in.o.old net/caif/built-in.o.old
text data bss dec hex filename
32297 700 8224 41221 a105 drivers/net/caif/built-in.o.old
72159 1317 20552 94028 16f4c net/caif/built-in.o.old
104456 2017 28776 135249 21051 (TOTALS)
$ size -t drivers/net/caif/built-in.o.new net/caif/built-in.o.new
text data bss dec hex filename
31975 700 8184 40859 9f9b drivers/net/caif/built-in.o.new
70748 1317 20152 92217 16839 net/caif/built-in.o.new
102723 2017 28336 133076 207d4 (TOTALS)Signed-off-by: Joe Perches
Signed-off-by: David S. Miller
23 May, 2011
1 commit
-
CAIF Socket layer - caif_socket.c:
- Plug mem-leak at reconnect.
- Always call disconnect to cleanup CAIF stack.
- Disconnect will always report success.CAIF configuration layer - cfcnfg.c
- Disconnect must dismantle the caif stack correctly
- Protect against faulty removals (check on id zero)CAIF mux layer - cfmuxl.c
- When inserting new service layer in the MUX remove
any old entries with the same ID.
- When removing CAIF Link layer, remove the associated
service layers before notifying service layers.Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller
16 May, 2011
5 commits
-
Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller -
Do proper handling of dev_queue_xmit errors in order to
avoid double free of skb and leaks in error conditions.
In cfctrl pending requests are removed when CAIF Link layer goes down.Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller -
Use struct net to reference CAIF configuration object instead of static variables.
Refactor functions caif_connect_client, caif_disconnect_client and squach
files cfcnfg.c and caif_config_utils.Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller -
Introduce Per-cpu reference for lower part of CAIF Stack.
Before freeing payload is disabled, synchronize_rcu() is called,
and then ref-count verified to be zero.Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller -
RCU lists are used for handling the link layers instead of array.
When generating CAIF phy-id, ifindex is used as base. Legal range is 1-6.
Introduced set_phy_state() for managing CAIF Link layer state.Signed-off-by: Sjur Brændeland
Signed-off-by: David S. Miller
12 Apr, 2011
1 commit
-
Cleanup of new CAIF code.
* make local functions static
* remove code that is never used
* expand get_caif_conf() since wrapper is no longer needed
* make args to comparison functions const
* rename connect_req_to_link_param to keep exported names
consistentCompile tested only.
Signed-off-by: Stephen Hemminger
Acked-by: Sjur Brændeland
Signed-off-by: David S. Miller
20 Jan, 2011
1 commit
-
Clean up some unused macros in net/*.
1. be left for code change. e.g. PGV_FROM_VMALLOC, PGV_FROM_VMALLOC, KMEM_SAFETYZONE.
2. never be used since introduced to kernel.
e.g. P9_RDMA_MAX_SGE, UTIL_CTRL_PKT_SIZE.Signed-off-by: Shan Wei
Acked-by: Sjur Braendeland
Signed-off-by: David S. Miller
16 Jan, 2011
1 commit
-
In the original code we check if (servl == NULL) twice. The first time
should print the message that cfmuxl_remove_uplayer() failed and set
"ret" correctly, but instead it just returns success. The second check
should be checking the value of "ret" instead of "servl".Signed-off-by: Dan Carpenter
Acked-by: Sjur Braendeland
Signed-off-by: David S. Miller
04 Nov, 2010
1 commit
-
Changes:
o Bugfix: SO_PRIORITY for SOL_SOCKET could not be handled
in caif's setsockopt, using the struct sock attribute priority instead.o Bugfix: SO_BINDTODEVICE for SOL_SOCKET could not be handled
in caif's setsockopt, using the struct sock attribute ifindex instead.o Wrong assert statement for RFM layer segmentation.
o CAIF Debug channels was not working over SPI, caif_payload_info
containing padding info must be initialized.o Check on pointer before dereferencing when unregister dev in caif_dev.c
Signed-off-by: Sjur Braendeland
Signed-off-by: David S. Miller
22 Sep, 2010
1 commit
-
Use pr_debug for flow control printouts, and refine an error printout.
Signed-off-by: Sjur Braendeland
Signed-off-by: David S. Miller
07 Sep, 2010
1 commit
-
This patch standardizes caif message logging prefixes.
Add #define pr_fmt(fmt) KBUILD_MODNAME ":%s(): " fmt, __func__
Add missing "\n"s to some logging messages
Convert pr_warning to pr_warnThis changes the logging message prefix from CAIF: to caif:
for all uses but caif_socket.c and chnl_net.c. Those now use
their filename without extension.Signed-off-by: Joe Perches
Signed-off-by: David S. Miller
21 Jun, 2010
2 commits
-
Previously CAIF supported maximum transfer size of ~4050.
The transfer size is now calculated dynamically based on the
link layers mtu size.Signed-off-by: Sjur Braendeland@stericsson.com
Signed-off-by: David S. Miller -
CAIF Remote File Manager may send or receive more than 4050 bytes.
Due to this The CAIF RFM service have to support segmentation.Signed-off-by: Sjur Braendeland@stericsson.com
Signed-off-by: David S. Miller
31 May, 2010
1 commit
-
"phyinfo" can never be null here because we assigned it an address, so I
removed both the assert and the second check inside the if statement. I
removed the "phyinfo->phy_layer != NULL" check as well because that was
asserted earlier.Walter Harms suggested I move the "phyinfo->phy_ref_count++;" outside
the if condition for readability, so I have done that.Signed-off-by: Dan Carpenter
Acked-by: Sjur Braendeland
Signed-off-by: David S. Miller
18 May, 2010
1 commit
-
Use kzalloc rather than the combination of kmalloc and memset.
A simplified version of the semantic patch that makes this change is as
follows: (http://coccinelle.lip6.fr/)//
@@
expression x,size,flags;
statement S;
@@-x = kmalloc(size,flags);
+x = kzalloc(size,flags);
if (x == NULL) S
-memset(x, 0, size);
//Signed-off-by: Julia Lawall
Acked-by: Sjur Brændeland
Signed-off-by: David S. Miller
29 Apr, 2010
3 commits
-
Changes:
o Function cfcnfg_disconn_adapt_layer is changed to do asynchronous
disconnect, not waiting for any response from the modem. Due to this
the function cfcnfg_linkdestroy_rsp does nothing anymore.
o Because disconnect may take down a connection before a connect response
is received the function cfcnfg_linkup_rsp is checking if the client is
still waiting for the response, if not a disconnect request is sent to
the modem.
o cfctrl is no longer keeping track of pending disconnect requests.
o Added function cfctrl_cancel_req, which is used for deleting a pending
connect request if disconnect is done before connect response is received.
o Removed unused function cfctrl_insert_req2
o Added better handling of connect reject from modem.Signed-off-by: Sjur Braendeland
Signed-off-by: David S. Miller -
Changes:
o Added functions cfsrvl_get and cfsrvl_put.
o Added support release_client to use by socket and net device.
o Increase reference counting for in-flight packets from cfmuxlSigned-off-by: Sjur Braendeland
Signed-off-by: David S. Miller -
Changes:
o Renamed cfcnfg_del_adapt_layer to cfcnfg_disconn_adapt_layer
o Fixed typo cfcfg to cfcnfg
o Renamed linkid to channel_id
o Updated documentation in caif_dev.h
o Minor formatting changesSigned-off-by: Sjur Braendeland
Signed-off-by: David S. Miller
01 Apr, 2010
1 commit
-
Signed-off-by: Stephen Rothwell
Signed-off-by: David S. Miller
31 Mar, 2010
1 commit
-
Support functions for the caif protocol stack:
cfcnfg.c - CAIF Configuration Module used for
adding and removing drivers and connection
cfpkt_skbuff.c - CAIF Packet layer (SKB helper functions)Signed-off-by: Sjur Braendeland
Signed-off-by: David S. Miller