Skip to content

Commit e825b81

Browse files
committed
applications: serial_lte_modem: remove deprecated RAI
Remove deprecated RAI socket options. Signed-off-by: Mirko Covizzi <[email protected]>
1 parent c9fdb5f commit e825b81

File tree

4 files changed

+20
-31
lines changed

4 files changed

+20
-31
lines changed

applications/serial_lte_modem/src/slm_at_socket.c

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -354,26 +354,6 @@ static int at_sockopt_to_sockopt(enum at_sockopt at_option, int *level, int *opt
354354
*level = SOL_SOCKET;
355355
*option = SO_RAI;
356356
break;
357-
case AT_SO_RAI_NO_DATA:
358-
*level = SOL_SOCKET;
359-
*option = SO_RAI_NO_DATA;
360-
break;
361-
case AT_SO_RAI_LAST:
362-
*level = SOL_SOCKET;
363-
*option = SO_RAI_LAST;
364-
break;
365-
case AT_SO_RAI_ONE_RESP:
366-
*level = SOL_SOCKET;
367-
*option = SO_RAI_ONE_RESP;
368-
break;
369-
case AT_SO_RAI_ONGOING:
370-
*level = SOL_SOCKET;
371-
*option = SO_RAI_ONGOING;
372-
break;
373-
case AT_SO_RAI_WAIT_MORE:
374-
*level = SOL_SOCKET;
375-
*option = SO_RAI_WAIT_MORE;
376-
break;
377357
case AT_SO_TCP_SRV_SESSTIMEO:
378358
*level = IPPROTO_TCP;
379359
*option = SO_TCP_SRV_SESSTIMEO;
@@ -404,11 +384,6 @@ static int sockopt_set(enum at_sockopt at_option, int at_value)
404384
tmo.tv_sec = at_value;
405385
value = &tmo;
406386
len = sizeof(tmo);
407-
} else if (level == SOL_SOCKET && (option == SO_RAI_LAST || option == SO_RAI_NO_DATA ||
408-
option == SO_RAI_ONE_RESP || option == SO_RAI_ONGOING ||
409-
option == SO_RAI_WAIT_MORE)) {
410-
value = NULL;
411-
len = 0;
412387
}
413388

414389
ret = setsockopt(sock.fd, level, option, value, len);

applications/serial_lte_modem/src/slm_sockopt.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,6 @@ enum at_sockopt {
2424
AT_SO_IP_ECHO_REPLY = 31,
2525
AT_SO_IPV6_ECHO_REPLY = 32,
2626
AT_SO_BINDTOPDN = 40,
27-
AT_SO_RAI_NO_DATA = 50,
28-
AT_SO_RAI_LAST = 51,
29-
AT_SO_RAI_ONE_RESP = 52,
30-
AT_SO_RAI_ONGOING = 53,
31-
AT_SO_RAI_WAIT_MORE = 54,
3227
AT_SO_TCP_SRV_SESSTIMEO = 55,
3328
AT_SO_RAI = 61,
3429
};

doc/nrf/releases_and_maturity/migration/migration_guide_2.8.rst

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,25 @@ Samples and applications
3333

3434
This section describes the changes related to samples and applications.
3535

36-
|no_changes_yet_note|
36+
Serial LTE Modem (SLM)
37+
----------------------
38+
39+
.. toggle::
40+
41+
* The handling of Release Assistance Indication (RAI) socket options has been updated in the ``#XSOCKETOPT`` command.
42+
The individual RAI-related socket options have been consolidated into a single ``SO_RAI`` option.
43+
You must modify your application to use the new ``SO_RAI`` option with the corresponding value to specify the RAI behavior.
44+
The changes are as follows:
45+
46+
The ``SO_RAI_NO_DATA``, ``SO_RAI_LAST``, ``SO_RAI_ONE_RESP``, ``SO_RAI_ONGOING``, and ``SO_RAI_WAIT_MORE`` options have been replaced by the ``SO_RAI`` option with values from ``1`` to ``5``.
47+
48+
Replace the following commands in your application code if they were used previously:
49+
50+
* ``AT#XSOCKETOPT=1,50,`` with ``AT#XSOCKETOPT=1,61,1`` to indicate ``RAI_NO_DATA``.
51+
* ``AT#XSOCKETOPT=1,51,`` with ``AT#XSOCKETOPT=1,61,2`` to indicate ``RAI_LAST``.
52+
* ``AT#XSOCKETOPT=1,52,`` with ``AT#XSOCKETOPT=1,61,3`` to indicate ``RAI_ONE_RESP``.
53+
* ``AT#XSOCKETOPT=1,53,`` with ``AT#XSOCKETOPT=1,61,4`` to indicate ``RAI_ONGOING``.
54+
* ``AT#XSOCKETOPT=1,54,`` with ``AT#XSOCKETOPT=1,61,5`` to indicate ``RAI_WAIT_MORE``.
3755

3856
Libraries
3957
=========

doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,7 @@ Serial LTE modem
241241
* Removed:
242242

243243
* Support for the :file:`overlay-native_tls.conf` configuration file with the ``thingy91/nrf9160/ns`` board target.
244+
* Support for deprecated RAI socket options ``AT_SO_RAI_LAST``, ``AT_SO_RAI_NO_DATA``, ``AT_SO_RAI_ONE_RESP``, ``AT_SO_RAI_ONGOING``, and ``AT_SO_RAI_WAIT_MORE``.
244245

245246
* Updated:
246247

0 commit comments

Comments
 (0)