#NEWLINE# def basepages( self , offset , length ) : #NEWLINE# #INDENT# basepages = [ ] #NEWLINE# basepages . append ( ( ( offset - ( offset % 4096 ) ) , ( offset % 4096 ) , ( 4096 - ( offset % 4096 ) ) ) ) #NEWLINE# length -= ( 4096 - ( offset % 4096 ) ) #NEWLINE# offset += 4096 #NEWLINE# while ( length >= 4096 ) : #NEWLINE# #INDENT# basepages . append ( ( offset , 0 , 4096 ) ) #NEWLINE# length -= 4096 #NEWLINE# offset += 4096 #NEWLINE# #UNINDENT# if ( length > 0 ) : #NEWLINE# #INDENT# basepages . append ( ( offset , 0 , length ) ) #NEWLINE# #UNINDENT# return basepages