Skip to content

Commit

Permalink
openonload-201405-u2
Browse files Browse the repository at this point in the history
    157a75b89b187f63326bbd1574681b40  openonload-201405-u2.tgz
  • Loading branch information
solarflare authored and majek committed Dec 15, 2014
1 parent 0afc556 commit bb56045
Show file tree
Hide file tree
Showing 8 changed files with 59 additions and 17 deletions.
9 changes: 9 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@

openonload-201405-u2
--------------------

Updated net driver to build on recent kernels (v4.1.2.1003b)
SF-113792-KI/Bug49194: ef_vi avoid registering wrong pages when ef_memreg_alloc() page sizes vary
SF-113764-KI/Bug48491: do not leak memory when querying status of LACP bond


openonload-201405-u1
--------------------

Expand Down
6 changes: 3 additions & 3 deletions README
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,6 @@ Any questions?


==========
version: openonload-201405-u1
revision: bc13f0dcf8c7 (ool1405) openonload-201405-u1/openonload-201405-u1-rc9
date: Thu Jul 31 14:28:11 BST 2014
version: openonload-201405-u2
revision: 91fcd3b34791 (ool1405) openonload-201405-u2-rc3
date: Mon Dec 8 10:30:22 GMT 2014
26 changes: 26 additions & 0 deletions ReleaseNotes
Original file line number Diff line number Diff line change
@@ -1,4 +1,30 @@

OpenOnload-201405-u2 Release Notes
==================================

This is an update release that fixes two important bugs in the
openonload-201405-u1 release.

The first is in the ef_vi API included with Onload. This concerns the
way that memory is registered via the ef_vi API (it does not affect
users who only use Onload) and can result in arbitrary memory on the
system becoming corrupted. Please see SF-113792-KI in the known
issues database on https://support.solarflare.com/ for full details.

The second is in the bonding code within Onload, and fixes a memory
leak that occurs once an LACP 802.3ad bond is configured on the
system. Please see SF-113764-KI in the known issues database on
https://support.solarflare.com/ for full details.

In addition, an updated net driver is included to allow building on
RHEL6.6 and other recent Linux kernel versions.

Please see the ChangeLog file for details of the changes in this release.

The Release Notes for the openonload-201405-u1 release are included at the
end of this file.


OpenOnload-201405-u1 Release Notes
==================================

Expand Down
2 changes: 1 addition & 1 deletion scripts/onload_misc/openonload.spec
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
# support older distros) to update this spec to use kernel modules packaging
# templates.

%define pkgversion 201405-u1
%define pkgversion 201405-u2

%{!?kernel: %{expand: %%define kernel %%(uname -r)}}
%{!?target_cpu: %{expand: %%define target_cpu %{_host_cpu}}}
Expand Down
16 changes: 14 additions & 2 deletions src/driver/linux_char/efch_memreg.c
Original file line number Diff line number Diff line change
Expand Up @@ -144,13 +144,25 @@ memreg_rm_alloc(ci_resource_alloc_t* alloc_,
goto fail3;
}

/* Take the order of the first page as our order to start with. */
mr->order = compound_order(mr->pages[0]);

/* If the size of the memreg isn't a multiple of pages of mr->order we
* know there must be pages of a different order present.
*/
if (mr->order != 0 && (mr->n_pages & (((1 << mr->order) - 1))) != 0)
mr->order = 0;

/* Check the rest of the pages, to ensure that they're all the right order,
* otherwise just use order 0.
*/
if (mr->order != 0) {
int i;
for (i = 0; i < mr->n_pages >> mr->order; i += 1 << mr->order) {
if (compound_order(mr->pages[i << mr->order]) != mr->order) {
/* Here i indexes pages of size PAGE_SIZE. We check the order for the first
* page in each compound page, incrementing i to skip the tail pages.
*/
for (i = 0; i < mr->n_pages; i += 1 << mr->order) {
if (compound_order(mr->pages[i]) != mr->order) {
mr->order = 0;
break;
}
Expand Down
2 changes: 1 addition & 1 deletion src/driver/linux_net/net_driver.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
*
**************************************************************************/

#define EFX_DRIVER_VERSION "4.1.2.1003"
#define EFX_DRIVER_VERSION "4.1.2.1003b"

#ifdef DEBUG
#define EFX_BUG_ON_PARANOID(x) BUG_ON(x)
Expand Down
13 changes: 4 additions & 9 deletions src/driver/linux_onload/bonding.c
Original file line number Diff line number Diff line change
Expand Up @@ -264,8 +264,10 @@ static int ci_bonding_get_hash_policy(char *bond_name, int *policy)
len = strlen(bond_name) +
SYSFS_BASE_STRLEN + SYSFS_HASHPOLICY_LEAF_STRLEN + 1;
filename = kmalloc(len, GFP_KERNEL);
if ( filename == NULL )
if ( filename == NULL ) {
kfree(buffer);
return -ENOMEM;
}

sprintf(filename, SYSFS_BASE, bond_name, SYSFS_HASHPOLICY_LEAF);

Expand Down Expand Up @@ -591,7 +593,6 @@ ci_bonding_get_lacp_active_slaves_entry_fn(ci_dllist* active_slaves,
static int ci_bonding_get_lacp_active_slave(char* bond_name, char* slave_name)
{
int len, rc;
char* buffer;
char* filename;
struct ci_read_proc_net_bonding_state state;
ci_dllist active_slaves;
Expand All @@ -600,16 +601,10 @@ static int ci_bonding_get_lacp_active_slave(char* bond_name, char* slave_name)
state.current_slave[0] = '\0';
ci_dllist_init(&active_slaves);

buffer = kmalloc(SYSFS_READ_BLOCK_SIZE + 1, GFP_KERNEL);
if ( buffer == NULL )
return -ENOMEM;

len = strlen(bond_name) + PROC_NET_BONDING_STRLEN + 1;
filename = kmalloc(len, GFP_KERNEL);
if ( filename == NULL ) {
kfree(buffer);
if ( filename == NULL )
return -ENOMEM;
}

sprintf(filename, PROC_NET_BONDING_BASE, bond_name);

Expand Down
2 changes: 1 addition & 1 deletion src/include/onload/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@


#ifndef ONLOAD_VERSION
# define ONLOAD_VERSION "201405-u1"
# define ONLOAD_VERSION "201405-u2"
#endif

#define ONLOAD_PRODUCT "OpenOnload"
Expand Down

0 comments on commit bb56045

Please sign in to comment.