re: CVS commit: src/sys/uvm

2018-12-09 Thread matthew green
"Jaromir Dolecek" writes:
> Module Name:  src
> Committed By: jdolecek
> Date: Sun Dec  9 20:45:37 UTC 2018
> 
> Modified Files:
>   src/sys/uvm: uvm_bio.c
> 
> Log Message:
> for direct map case, avoid PGO_NOBLOCKALLOC when writing, it makes
> genfs_getpages() return unallocated pages using the zero page and
> PG_RDONLY; the old code relied on fault logic to get it allocated, which
> the direct case can't rely on
> 
> instead just allocate the blocks right away; pass PGO_JOURNALLOCKED
> so that code wouldn't try to take wapbl lock, this code path is called
> with it already held

can you assert this if not already done?  that the locking is OK,
i mean...

thanks.


.mrg.


Re: CVS commit: src/sys

2018-12-09 Thread Jason Thorpe
Fixed.

> On Dec 9, 2018, at 7:50 AM, Jason Thorpe  wrote:
> 
> Investigating now...
> 
>> On Dec 9, 2018, at 7:39 AM, m...@netbsd.org wrote:
>> 
>> On Sat, Dec 08, 2018 at 05:46:15PM +, Jason R Thorpe wrote:
>>> @@ -2508,13 +2525,7 @@ comcnattach(bus_space_tag_t iot, bus_add
>>> {
>>> struct com_regs regs;
>>> 
>>> -   memset(, 0, sizeof regs);
>>> -   regs.cr_iot = iot;
>>> -   regs.cr_iobase = iobase;
>>> -   regs.cr_nports = COM_NPORTS;
>>> -#ifdef COM_REGMAP
>>> -   memcpy(regs.cr_map, com_std_map, sizeof (regs.cr_map));
>>> -#endif
>>> +   com_init_regs(, iot, (bus_space_handle_t)0/*XXX*/, iobase);
>>> 
>>> return comcnattach1(, rate, frequency, type, cflag);
>>> }
>> 
>> This breaks the build for sparc:
>> https://releng.netbsd.org/builds/HEAD/201812090350Z/sparc64.build.failed
>> 
>> /home/source/ab/HEAD/src/sys/dev/ic/com.c: In function 'comcnattach':
>> /home/source/ab/HEAD/src/sys/dev/ic/com.c:2511:2: error: conversion to 
>> non-scalar type requested
>> com_init_regs(, iot, (bus_space_handle_t)0/*XXX*/, iobase);
>> ^
>> 
>> Any idea?
> 
> -- thorpej
> 

-- thorpej



Re: CVS commit: src/sys

2018-12-09 Thread Jason Thorpe
Investigating now...

> On Dec 9, 2018, at 7:39 AM, m...@netbsd.org wrote:
> 
> On Sat, Dec 08, 2018 at 05:46:15PM +, Jason R Thorpe wrote:
>> @@ -2508,13 +2525,7 @@ comcnattach(bus_space_tag_t iot, bus_add
>> {
>>  struct com_regs regs;
>> 
>> -memset(, 0, sizeof regs);
>> -regs.cr_iot = iot;
>> -regs.cr_iobase = iobase;
>> -regs.cr_nports = COM_NPORTS;
>> -#ifdef  COM_REGMAP
>> -memcpy(regs.cr_map, com_std_map, sizeof (regs.cr_map));
>> -#endif
>> +com_init_regs(, iot, (bus_space_handle_t)0/*XXX*/, iobase);
>> 
>>  return comcnattach1(, rate, frequency, type, cflag);
>> }
> 
> This breaks the build for sparc:
> https://releng.netbsd.org/builds/HEAD/201812090350Z/sparc64.build.failed
> 
> /home/source/ab/HEAD/src/sys/dev/ic/com.c: In function 'comcnattach':
> /home/source/ab/HEAD/src/sys/dev/ic/com.c:2511:2: error: conversion to 
> non-scalar type requested
>  com_init_regs(, iot, (bus_space_handle_t)0/*XXX*/, iobase);
>  ^
> 
> Any idea?

-- thorpej



Re: CVS commit: src/sys

2018-12-09 Thread maya
On Sat, Dec 08, 2018 at 05:46:15PM +, Jason R Thorpe wrote:
> @@ -2508,13 +2525,7 @@ comcnattach(bus_space_tag_t iot, bus_add
>  {
>   struct com_regs regs;
>  
> - memset(, 0, sizeof regs);
> - regs.cr_iot = iot;
> - regs.cr_iobase = iobase;
> - regs.cr_nports = COM_NPORTS;
> -#ifdef   COM_REGMAP
> - memcpy(regs.cr_map, com_std_map, sizeof (regs.cr_map));
> -#endif
> + com_init_regs(, iot, (bus_space_handle_t)0/*XXX*/, iobase);
>  
>   return comcnattach1(, rate, frequency, type, cflag);
>  }

This breaks the build for sparc:
https://releng.netbsd.org/builds/HEAD/201812090350Z/sparc64.build.failed

/home/source/ab/HEAD/src/sys/dev/ic/com.c: In function 'comcnattach':
/home/source/ab/HEAD/src/sys/dev/ic/com.c:2511:2: error: conversion to 
non-scalar type requested
  com_init_regs(, iot, (bus_space_handle_t)0/*XXX*/, iobase);
  ^

Any idea?