|
From: Peter K. <pk...@us...> - 2001-09-12 12:18:34
|
The following file was modified in linux/drivers/char/bluetooth:
Name Old version New version Comment
---- ----------- ----------- -------
hci.c 1.178 1.179=20=20=20=20=20=20=20=20=20=20=20
The accompanying log:
Improved load calculation.
The diff of the modified file(s):
--- hci.c 2001/09/12 12:12:29 1.178
+++ hci.c 2001/09/12 12:18:34 1.179
@@ -2752,14 +2752,11 @@
{
static unsigned char load;
=20
- /* Makes a rough calculation of the current load */=20
- if ((bt_max_connections =3D=3D hci_ctrl.nbr_of_connections) ||
- (bt_max_connections =3D=3D 0))
- load =3D 0x07;
- else if (bt_max_connections >=3D 4)
- load =3D hci_ctrl.nbr_of_connections;
+ /* Calculate the current load */
+ if (!bt_max_connections)
+ load =3D 7;
else
- load =3D hci_ctrl.nbr_of_connections*2;
+ load =3D 7 * hci_ctrl.nbr_of_connections / bt_max_connections;
=20
/* Make sure only bit2 to bit0 are used */
load &=3D 0x07;
|